mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-04 09:59:32 +00:00
SUNRPC: call_connect_status() must handle tasks that got transmitted
If a task failed to get the write lock in the call to xprt_connect(), then it will be queued on xprt->sending. In that case, it is possible for it to get transmitted before the call to call_connect_status(), in which case it needs to be handled by call_transmit_status() instead. Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
This commit is contained in:
parent
ad3cba223a
commit
9bd11523dc
1 changed files with 7 additions and 0 deletions
|
@ -1915,6 +1915,13 @@ call_connect_status(struct rpc_task *task)
|
|||
struct rpc_clnt *clnt = task->tk_client;
|
||||
int status = task->tk_status;
|
||||
|
||||
/* Check if the task was already transmitted */
|
||||
if (!test_bit(RPC_TASK_NEED_XMIT, &task->tk_runstate)) {
|
||||
xprt_end_transmit(task);
|
||||
task->tk_action = call_transmit_status;
|
||||
return;
|
||||
}
|
||||
|
||||
dprint_status(task);
|
||||
|
||||
trace_rpc_connect_status(task);
|
||||
|
|
Loading…
Reference in a new issue