[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200921235136.GA6796@gondor.apana.org.au>
Date: Tue, 22 Sep 2020 09:51:36 +1000
From: Herbert Xu <herbert@...dor.apana.org.au>
To: "Paul E. McKenney" <paulmck@...nel.org>
Cc: Eric Biggers <ebiggers@...nel.org>, tytso@....edu,
linux-kernel@...r.kernel.org, linux-crypto@...r.kernel.org,
stable@...r.kernel.org,
Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: [PATCH] random: use correct memory barriers for crng_node_pool
On Mon, Sep 21, 2020 at 04:26:39PM -0700, Paul E. McKenney wrote:
>
> > But this reasoning could apply to any data structure that contains
> > a spin lock, in particular ones that are dereferenced through RCU.
>
> I lost you on this one. What is special about a spin lock?
I don't know, that was Eric's concern. He is inferring that
spin locks through lockdep debugging may trigger dependencies
that require smp_load_acquire.
Anyway, my point is if it applies to crng_node_pool then it
would equally apply to RCU in general.
> > So my question if this reasoning is valid, then why aren't we first
> > converting rcu_dereference to use smp_load_acquire?
>
> For LTO in ARM, rumor has it that Will is doing so. Which was what
> motivated the BoF on this topic at Linux Plumbers Conference.
Sure, if RCU switches over to smp_load_acquire then I would have
no problems with everybody else following in its footsteps.
Here is the original patch in question:
https://lore.kernel.org/lkml/20200916233042.51634-1-ebiggers@kernel.org/
Cheers,
--
Email: Herbert Xu <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Powered by blists - more mailing lists