Re: [PATCH 2/2] workqueue: fix possible deadlock in idle worker rebinding

2012-09-05 Thread Lai Jiangshan
On 09/06/2012 07:11 AM, Tejun Heo wrote: > On Tue, Sep 04, 2012 at 11:16:32PM -0700, Tejun Heo wrote: >> Currently, rebind_workers() and idle_worker_rebind() are two-way >> interlocked. rebind_workers() waits for idle workers to finish >> rebinding and rebound idle workers wait for rebind_workers(

Re: [PATCH 2/2] workqueue: fix possible deadlock in idle worker rebinding

2012-09-05 Thread Tejun Heo
On Tue, Sep 04, 2012 at 11:16:32PM -0700, Tejun Heo wrote: > Currently, rebind_workers() and idle_worker_rebind() are two-way > interlocked. rebind_workers() waits for idle workers to finish > rebinding and rebound idle workers wait for rebind_workers() to finish > rebinding busy workers before pr

[PATCH 2/2] workqueue: fix possible deadlock in idle worker rebinding

2012-09-04 Thread Tejun Heo
Currently, rebind_workers() and idle_worker_rebind() are two-way interlocked. rebind_workers() waits for idle workers to finish rebinding and rebound idle workers wait for rebind_workers() to finish rebinding busy workers before proceeding. Unfortunately, this isn't enough. The second wait from