diff mbox series

[RFC,1/6] NFSD: Remove dead code in nfsd4_create_session()

Message ID 20241017150349.216096-9-cel@kernel.org (mailing list archive)
State New
Headers show
Series Fix nits found by static analysis | expand

Commit Message

Chuck Lever Oct. 17, 2024, 3:03 p.m. UTC
From: Chuck Lever <chuck.lever@oracle.com>

Clean up. AFAICT, there is no way to reach the out_free_conn label
with @old set to a non-NULL value, so the expire_client(old) call
is never reached and can be removed.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
---
 fs/nfsd/nfs4state.c | 3 ---
 1 file changed, 3 deletions(-)
diff mbox series

Patch

diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index 2b21f2113c6e..3b16468ecbe7 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -3927,7 +3927,6 @@  nfsd4_create_session(struct svc_rqst *rqstp,
 	return status;
 
 out_expired_error:
-	old = NULL;
 	/*
 	 * Revert the slot seq_nr change so the server will process
 	 * the client's resend instead of returning a cached response.
@@ -3942,8 +3941,6 @@  nfsd4_create_session(struct svc_rqst *rqstp,
 out_free_conn:
 	spin_unlock(&nn->client_lock);
 	free_conn(conn);
-	if (old)
-		expire_client(old);
 out_free_session:
 	__free_session(new);
 out_release_drc_mem: