This is a note to let you know that I've just added the patch titled nfsd: rpc_peeraddr2str needs rcu lock to the 5.10-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: nfsd-rpc_peeraddr2str-needs-rcu-lock.patch and it can be found in the queue-5.10 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. commit d98ffe935d8862c3a349135d864a7bc173843e72 Author: J. Bruce Fields <bfields@xxxxxxxxxxxx> Date: Mon Jun 14 11:20:49 2021 -0400 nfsd: rpc_peeraddr2str needs rcu lock [ Upstream commit 05570a2b01117209b500e1989ce8f1b0524c489f ] I'm not even sure cl_xprt can change here, but we're getting "suspicious RCU usage" warnings, and other rpc_peeraddr2str callers are taking the rcu lock. Signed-off-by: J. Bruce Fields <bfields@xxxxxxxxxx> Signed-off-by: Chuck Lever <chuck.lever@xxxxxxxxxx> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> diff --git a/fs/nfsd/nfs4callback.c b/fs/nfsd/nfs4callback.c index 59dc80ecd3764..97f517e9b4189 100644 --- a/fs/nfsd/nfs4callback.c +++ b/fs/nfsd/nfs4callback.c @@ -941,8 +941,10 @@ static int setup_callback_client(struct nfs4_client *clp, struct nfs4_cb_conn *c clp->cl_cb_conn.cb_xprt = conn->cb_xprt; clp->cl_cb_client = client; clp->cl_cb_cred = cred; + rcu_read_lock(); trace_nfsd_cb_setup(clp, rpc_peeraddr2str(client, RPC_DISPLAY_NETID), args.authflavor); + rcu_read_unlock(); return 0; }