On 1/30/07, Rajat Jain <rajat.noida.india@xxxxxxxxx> wrote:
On 1/29/07, Ramagudi Naziir <naziirr@xxxxxxxxx> wrote: > Hello. > > My driver needs to wait for the hardware to complete something. > I obviously want it to sleep (it is process context), > and when the operation will finish it will wake up the sleeping > context (the waking up will be in interrupt context). > > Should I use completion variables or wait queues sleeping ? > > Which is preferred / recommended ? > Aren't completion variables "one shot"? I mean once completion is signalled the job is done (You can't re-use)! Please CMIIW
No. it can be used as you wish. only note is after you use complete_all, you must reinitialize it with INIT_COMPLETION. the question is when to use each of them techniques ? naziir.
Regards, Rajat
-- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/