]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
NFSv4: Fix a nfs4_state_manager() race
authorTrond Myklebust <trond.myklebust@hammerspace.com>
Sun, 17 Sep 2023 23:05:50 +0000 (19:05 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 10 Oct 2023 19:59:07 +0000 (21:59 +0200)
commit9fb4dfb8e2120b7d4153ea83601367b04db8dfd4
treef3289f075db0ca66fc52c245d96c98fd5d97859b
parentfcdd79fda38ad9a746139e421892faa27b5b9189
NFSv4: Fix a nfs4_state_manager() race

[ Upstream commit ed1cc05aa1f7fe8197d300e914afc28ab9818f89 ]

If the NFS4CLNT_RUN_MANAGER flag got set just before we cleared
NFS4CLNT_MANAGER_RUNNING, then we might have won the race against
nfs4_schedule_state_manager(), and are responsible for handling the
recovery situation.

Fixes: aeabb3c96186 ("NFSv4: Fix a NFSv4 state manager deadlock")
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/nfs/nfs4state.c