提交 25b31f15 编写于 作者: T Trond Myklebust 提交者: Zheng Zengkai

SUNRPC: RPC level errors should set task->tk_rpc_status

stable inclusion
from stable-v5.10.140
commit 8be096f018e4d4a4d430c8c87c4009c7024ffb90
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I63FTT

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=8be096f018e4d4a4d430c8c87c4009c7024ffb90

--------------------------------

[ Upstream commit ed06fce0 ]

Fix up a case in call_encode() where we're failing to set
task->tk_rpc_status when an RPC level error occurred.

Fixes: 9c5948c2 ("SUNRPC: task should be exit if encode return EKEYEXPIRED more times")
Signed-off-by: NTrond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: NSasha Levin <sashal@kernel.org>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Reviewed-by: NWei Li <liwei391@huawei.com>
上级 e1d79e6b
...@@ -1867,7 +1867,7 @@ call_encode(struct rpc_task *task) ...@@ -1867,7 +1867,7 @@ call_encode(struct rpc_task *task)
break; break;
case -EKEYEXPIRED: case -EKEYEXPIRED:
if (!task->tk_cred_retry) { if (!task->tk_cred_retry) {
rpc_exit(task, task->tk_status); rpc_call_rpcerror(task, task->tk_status);
} else { } else {
task->tk_action = call_refresh; task->tk_action = call_refresh;
task->tk_cred_retry--; task->tk_cred_retry--;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册