[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How do I make a kernel module "sleep" without affecting other kernel modules?



On Wed, 2004-12-01 at 08:14 +0530, Karthik Subramanian wrote:
> I wonder if it's bad practice to set current->state directly instead
> of using a function like set_current_state (like the way msleep does
> in the current kernel source) ?

yes it is; you miss the "wmb()" that way which is a bug (altough
basically harmless for x86; less so for other processors).
-- 


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/