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: <Zy0zM8Qc0-9SVVpB@kbusch-mbp>
Date: Thu, 7 Nov 2024 14:37:55 -0700
From: Keith Busch <kbusch@...nel.org>
To: Breno Leitao <leitao@...ian.org>
Cc: Jens Axboe <axboe@...nel.dk>, Christoph Hellwig <hch@....de>,
	Sagi Grimberg <sagi@...mberg.me>, linux-nvme@...ts.infradead.org,
	linux-kernel@...r.kernel.org, kernel-team@...a.com
Subject: Re: [PATCH] nvme/multipath: Fix RCU list traversal to use SRCU
 primitive

On Tue, Nov 05, 2024 at 06:42:46AM -0800, Breno Leitao wrote:
> The code currently uses list_for_each_entry_rcu() while holding an SRCU
> lock, triggering false positive warnings with CONFIG_PROVE_RCU=y
> enabled:
> 
> 	drivers/nvme/host/multipath.c:168 RCU-list traversed in non-reader section!!
> 	drivers/nvme/host/multipath.c:227 RCU-list traversed in non-reader section!!
> 	drivers/nvme/host/multipath.c:260 RCU-list traversed in non-reader section!!
> 
> While the list is properly protected by SRCU lock, the code uses the
> wrong list traversal primitive. Replace list_for_each_entry_rcu() with
> list_for_each_entry_srcu() to correctly indicate SRCU-based protection
> and eliminate the false warning.

Thanks, applied to nvme-6.12. Sorry I missed this was posted until after
I'd sent this week's pull request, but this will make the next one.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ