lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20200930155638.GA4441@mtj.duckdns.org>
Date:   Wed, 30 Sep 2020 11:56:38 -0400
From:   Tejun Heo <tj@...nel.org>
To:     qiang.zhang@...driver.com
Cc:     pmladek@...e.com, hdanton@...a.com, akpm@...ux-foundation.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3] kthread_worker: Prevent queuing delayed work from
 timer_fn when it is being canceled

On Sun, Sep 27, 2020 at 01:54:49PM +0800, qiang.zhang@...driver.com wrote:
> From: Zqiang <qiang.zhang@...driver.com>
> 
> There is a small race window when a delayed work is being canceled and
> the work still might be queued from the timer_fn:
> 
> 	CPU0						CPU1
> kthread_cancel_delayed_work_sync()
>    __kthread_cancel_work_sync()
>      __kthread_cancel_work()
>         work->canceling++;
> 					      kthread_delayed_work_timer_fn()
> 						   kthread_insert_work();
> 
> BUG: kthread_insert_work() should not get called when work->canceling
> is set.
> 
> Reviewed-by: Petr Mladek <pmladek@...e.com>
> Signed-off-by: Zqiang <qiang.zhang@...driver.com>

Acked-by: Tejun Heo <tj@...nel.org>

This prolly should go throgh -mm. Can you please also add a stable: tag?

Thanks.

-- 
tejun

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ