projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
31d90de
)
SUNRPC: Don't try to send when the connection is shutting down
author
Trond Myklebust
<trond.myklebust@hammerspace.com>
Tue, 12 Dec 2023 14:34:08 +0000
(15:34 +0100)
committer
Trond Myklebust
<trond.myklebust@hammerspace.com>
Wed, 28 Feb 2024 20:00:14 +0000
(15:00 -0500)
If the connection has been scheduled to shut down, we must assume that
the socket is not in a state to accept further transmissions until the
connection has been re-established.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
net/sunrpc/xprt.c
patch
|
blob
|
history
diff --git
a/net/sunrpc/xprt.c
b/net/sunrpc/xprt.c
index af13fdfa6672146daf1b572aa29a8d4bd3731b1d..db3754a3298f9df7c9ef870bc588aaf19a9a119d 100644
(file)
--- a/
net/sunrpc/xprt.c
+++ b/
net/sunrpc/xprt.c
@@
-1541,6
+1541,9
@@
xprt_request_transmit(struct rpc_rqst *req, struct rpc_task *snd_task)
int is_retrans = RPC_WAS_SENT(task);
int status;
+ if (test_bit(XPRT_CLOSE_WAIT, &xprt->state))
+ return -ENOTCONN;
+
if (!req->rq_bytes_sent) {
if (xprt_request_data_received(task)) {
status = 0;