schedule_work and speedtch.c
rkagan at mail.ru
Sat Apr 16 14:12:08 EDT 2005
On Fri, Apr 15, 2005 at 05:24:33PM +0200, Duncan Sands wrote:
> The speedtouch driver checks the modem status by scheduling work
> in the common kernel workqueue. My nasty old speedtouch has the
> unpleasant habit of failing control transfers for no obvious
> reason. When this happens, the control messages timeout when
> reading the status. This causes the entire computer to freeze
> for the length of the timeout since the workqueue is blocked,
> and lots of important stuff runs there.
Hmm, I didn't realize keventd runs everything synchronously...
> I guess the speedtouch (or the usbatm core) could
> get its own workqueue.
Agreed. I think doing it in the usbatm core is better: it can be useful
to other drivers too, and to the core itself for doing usb_clear_halt()s
(e.g. like in the patch I've sent).
More information about the Usbatm