aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/fs/nfs/nfs4state.c
diff options
context:
space:
mode:
authorBenjamin Coddington <bcodding@redhat.com>2023-06-15 14:07:32 -0400
committerTrond Myklebust <trond.myklebust@hammerspace.com>2023-06-19 15:09:25 -0400
commit6ad477a69ad81bcdd515559fba2887ae71c9c0cc (patch)
tree5909d68ee80732527aea515776214f522d04a5bc /fs/nfs/nfs4state.c
parentNFS: Cancel all existing RPC tasks when shutdown (diff)
downloadwireguard-linux-6ad477a69ad81bcdd515559fba2887ae71c9c0cc.tar.xz
wireguard-linux-6ad477a69ad81bcdd515559fba2887ae71c9c0cc.zip
NFSv4: Clean up some shutdown loops
If a SEQUENCE call receives -EIO for a shutdown client, it will retry the RPC call. Instead of doing that for a shutdown client, just bail out. Likewise, if the state manager decides to perform recovery for a shutdown client, it will continuously retry. As above, just bail out. Signed-off-by: Benjamin Coddington <bcodding@redhat.com> Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'fs/nfs/nfs4state.c')
-rw-r--r--fs/nfs/nfs4state.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/nfs/nfs4state.c b/fs/nfs/nfs4state.c
index bbe49315d99e..e079987af4a3 100644
--- a/fs/nfs/nfs4state.c
+++ b/fs/nfs/nfs4state.c
@@ -1210,6 +1210,9 @@ void nfs4_schedule_state_manager(struct nfs_client *clp)
struct task_struct *task;
char buf[INET6_ADDRSTRLEN + sizeof("-manager") + 1];
+ if (clp->cl_rpcclient->cl_shutdown)
+ return;
+
set_bit(NFS4CLNT_RUN_MANAGER, &clp->cl_state);
if (test_and_set_bit(NFS4CLNT_MANAGER_AVAILABLE, &clp->cl_state) != 0) {
wake_up_var(&clp->cl_state);