[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250317-horned-nano-degu-a6e5bc@leitao>
Date: Mon, 17 Mar 2025 02:33:31 -0700
From: Breno Leitao <leitao@...ian.org>
To: Rik van Riel <riel@...riel.com>
Cc: Corey Minyard <corey@...yard.net>,
"Paul E. McKenney" <paulmck@...nel.org>,
openipmi-developer@...ts.sourceforge.net,
linux-kernel@...r.kernel.org, kernel-team@...a.com
Subject: Re: [PATCH] ipmi: fix suspicious RCU usage warning
On Wed, Mar 12, 2025 at 01:19:32PM -0400, Rik van Riel wrote:
> On recent kernels this warning fires:
>
> drivers/char/ipmi/ipmi_msghandler.c:1238 RCU-list traversed in non-reader section!!
>
> This looks like a fairly simple lockdep trigger, where
> list_for_each_entry_rcu and list_for_each_entry_srcu are
> functionally identical, but the lockdep annotation in
> the former has an extra check.
>
> That extra check is whether the RCU read lock is held,
> which is not true when the code uses srcu_read_lock.
>
> Get rid of the warning by using the properly annotated
> list traversal macro.
Thanks for looking at this one.
There was a discussion about this issue a few years ago, with
a different approach that never landed upstream.
https://lore.kernel.org/all/20201119123831.GH3710@minyard.net/#r
Powered by blists - more mailing lists