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]
Date:	Thu, 11 Aug 2016 16:25:39 -0400
From:	Tejun Heo <tj@...nel.org>
To:	Roman Pen <roman.penyaev@...fitbricks.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/1] percpu-refcount: init ->confirm_switch member
 properly

On Thu, Aug 11, 2016 at 07:27:09PM +0200, Roman Pen wrote:
> This patch targets two things which are related to ->confirm_switch:
> 
>  1. Init ->confirm_switch pointer with NULL on percpu_ref_init() or
>     kernel frightfully complains with WARN_ON_ONCE(ref->confirm_switch)
>     at __percpu_ref_switch_to_atomic if memory chunk was not properly
>     zeroed.
> 
>  2. Warn if RCU callback is still in progress on percpu_ref_exit().
>     The race still exists, because percpu_ref_call_confirm_rcu()
>     drops ->confirm_switch to NULL early, but that is only a warning
>     and still the caller is responsible that ref is no longer in
>     active use.  Hopefully that can help to catch incorrect usage
>     of percpu-refcount.
> 
> Signed-off-by: Roman Pen <roman.penyaev@...fitbricks.com>
> Cc: Tejun Heo <tj@...nel.org>
> Cc: linux-kernel@...r.kernel.org

Applied to percpu/for-4.9.

Thanks.

-- 
tejun

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ