提交 f05d54ec 编写于 作者: T Trond Myklebust

SUNRPC: Allow soft RPC calls to time out when waiting for the XPRT_LOCK

This no longer causes them to lose their place in the transmission queue.
Signed-off-by: NTrond Myklebust <trond.myklebust@hammerspace.com>
上级 89f90fe1
...@@ -195,7 +195,7 @@ int xprt_reserve_xprt(struct rpc_xprt *xprt, struct rpc_task *task) ...@@ -195,7 +195,7 @@ int xprt_reserve_xprt(struct rpc_xprt *xprt, struct rpc_task *task)
out_sleep: out_sleep:
dprintk("RPC: %5u failed to lock transport %p\n", dprintk("RPC: %5u failed to lock transport %p\n",
task->tk_pid, xprt); task->tk_pid, xprt);
task->tk_timeout = 0; task->tk_timeout = RPC_IS_SOFT(task) ? req->rq_timeout : 0;
task->tk_status = -EAGAIN; task->tk_status = -EAGAIN;
if (req == NULL) if (req == NULL)
priority = RPC_PRIORITY_LOW; priority = RPC_PRIORITY_LOW;
...@@ -274,7 +274,7 @@ int xprt_reserve_xprt_cong(struct rpc_xprt *xprt, struct rpc_task *task) ...@@ -274,7 +274,7 @@ int xprt_reserve_xprt_cong(struct rpc_xprt *xprt, struct rpc_task *task)
xprt_clear_locked(xprt); xprt_clear_locked(xprt);
out_sleep: out_sleep:
dprintk("RPC: %5u failed to lock transport %p\n", task->tk_pid, xprt); dprintk("RPC: %5u failed to lock transport %p\n", task->tk_pid, xprt);
task->tk_timeout = 0; task->tk_timeout = RPC_IS_SOFT(task) ? req->rq_timeout : 0;
task->tk_status = -EAGAIN; task->tk_status = -EAGAIN;
if (req == NULL) if (req == NULL)
priority = RPC_PRIORITY_LOW; priority = RPC_PRIORITY_LOW;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册