lkml.org 
[lkml]   [2014]   [Feb]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 5/9] usb: don't use PREPARE_DELAYED_WORK
On Sat, Feb 22, 2014 at 10:14:48AM -0500, Alan Stern wrote:
> Is the cancel_delayed_work_sync(&hub->init_work) call in hub_quiesce()
> going to get confused by all this?

Yeah, you can't cancel a work item which hasn't been initialzed.
Maybe move init of the first work function there? I don't think it
really matters tho.

> It's worth mentioning that the only reason for the hub_init_func3 stuff
> is, as the comment says, to avoid a long sleep (100 ms) inside a work
> routine. With all the changes to the work queue infrastructure, maybe
> this doesn't matter so much any more. If we got rid of it then there
> wouldn't be any multiplexing, and this whole issue would become moot.

I don't really think that'd be necessary. Just sleeping synchronously
should be fine. How many threads are we talking about?

Thanks.

--
tejun


\
 
 \ /
  Last update: 2014-02-22 17:21    [W:0.130 / U:0.768 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site