Re: [PATCH][USBATM]: convert heavy init dances to kthread API

From: Alan Stern
Date: Thu Feb 07 2008 - 11:18:33 EST


On Thu, 7 Feb 2008, Pavel Emelyanov wrote:

> > Does the kthread API guarantee that the kthread is not running until you call
>
> It does. That's why the race, you mentioned above is impossible.

That is wrong. The API guarantees only that the kthread is initially
created in a non-running state. It cannot guarantee that no other
task will wake up the kthread before the caller does.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/