Messages in this thread | | | Date | Mon, 24 Sep 2012 11:25:11 -0700 | From | Tejun Heo <> | Subject | Re: [PATCH] memstick: add support for legacy memorysticks |
| |
Hello,
On Mon, Sep 24, 2012 at 08:19:28PM +0200, Maxim Levitsky wrote: > Except that if I schedule a same work item few times, these work items > will be 'processed' in parallel, although there is just one work to do, > work of pulling the requests from block queue until it has them, and > dispatching them through my code. > Or I can get a guarantee that work items wont be processed in parallel?
You need to use system_nrt_wq for that before 3.7-rc1. After 3.7-rc1, any workqueue will guarantee that.
> Stiil, even with that only first work item will do the actual work, > others will wake the workqueue for nothing, but I am ok with that.
It's just like waking up spuriously. The work item is guaranteed to be executed at least once after any given schedule/queue_work() call.
Thanks.
-- tejun
| |