Messages in this thread | | | Subject | Re: [PATCH] workqueue: relax lockdep annotation on flush_work() | From | Peter Zijlstra <> | Date | Mon, 03 Jan 2011 10:31:31 +0100 |
| |
On Wed, 2010-12-29 at 13:57 +0100, Tejun Heo wrote: > Currently, the lockdep annotation in flush_work() requires exclusive > access on the workqueue the target work is queued on and triggers > warning if a work is trying to flush another work on the same > workqueue; however, this is no longer true as workqueues can now > execute multiple works concurrently. > > This patch adds lock_map_acquire_read() and make process_one_work() > hold read access to the workqueue while executing a work and > start_flush_work() check for write access if concurrnecy level is one > and read access if higher. > > This better represents what's going on and removes spurious lockdep > warnings which are triggered by fake dependency chain created through > flush_work().
Is this still true in the low memory situation where we're running the emergency thread? I can imagine the emergency thread trying to flush itself isn't really a good thing.
| |