lkml.org 
[lkml]   [2014]   [Jul]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] workqueue: detach rescuer from pool until the last
Hello,

On Wed, Jul 16, 2014 at 02:56:50PM +0800, Lai Jiangshan wrote:
> @@ -2300,11 +2300,6 @@ repeat:
> move_linked_works(work, scheduled, &n);
>
> process_scheduled_works(rescuer);
> - spin_unlock_irq(&pool->lock);
> -
> - worker_detach_from_pool(rescuer, pool);
> -
> - spin_lock_irq(&pool->lock);
>
> /*
> * Put the reference grabbed by send_mayday(). @pool won't
> @@ -2322,8 +2317,11 @@ repeat:
> wake_up_worker(pool);
>
> rescuer->pool = NULL;
> - spin_unlock(&pool->lock);
> - spin_lock(&wq_mayday_lock);
> + spin_unlock_irq(&pool->lock);
> +
> + worker_detach_from_pool(rescuer, pool);
> +
> + spin_lock_irq(&wq_mayday_lock);

Can you please also update the comment above put_pwq() and explain
above detach that @pool will stay around till detach is complete?

Thanks.

--
tejun


\
 
 \ /
  Last update: 2014-07-19 01:41    [W:0.097 / U:0.984 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site