]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
crypto: nx - Fix RCU warning in nx842_OF_upd_status
authorHerbert Xu <herbert@gondor.apana.org.au>
Thu, 17 Jun 2021 07:57:12 +0000 (15:57 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 20 Jul 2021 14:15:48 +0000 (16:15 +0200)
commitf85e7b202aa2e664ce6f58ad5817f8cc39ae8eeb
tree2d9a569e554529b474277bd8de115a1629febaa3
parented556eef5fedd69219dfa8e0e3864347eff8e76e
crypto: nx - Fix RCU warning in nx842_OF_upd_status

[ Upstream commit 2a96726bd0ccde4f12b9b9a9f61f7b1ac5af7e10 ]

The function nx842_OF_upd_status triggers a sparse RCU warning when
it directly dereferences the RCU-protected devdata.  This appears
to be an accident as there was another variable of the same name
that was passed in from the caller.

After it was removed (because the main purpose of using it, to
update the status member was itself removed) the global variable
unintenionally stood in as its replacement.

This patch restores the devdata parameter.

Fixes: 90fd73f912f0 ("crypto: nx - remove pSeries NX 'status' field")
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/crypto/nx/nx-842-pseries.c