mirror of
https://github.com/torvalds/linux.git
synced 2024-11-29 23:51:37 +00:00
SUNRPC: Refactor rpc_restart_call/rpc_restart_call_prepare
Clean up. Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
This commit is contained in:
parent
ae67bd3821
commit
9e6fa0bb84
@ -1464,20 +1464,13 @@ void rpc_force_rebind(struct rpc_clnt *clnt)
|
|||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(rpc_force_rebind);
|
EXPORT_SYMBOL_GPL(rpc_force_rebind);
|
||||||
|
|
||||||
/*
|
static int
|
||||||
* Restart an (async) RPC call from the call_prepare state.
|
__rpc_restart_call(struct rpc_task *task, void (*action)(struct rpc_task *))
|
||||||
* Usually called from within the exit handler.
|
|
||||||
*/
|
|
||||||
int
|
|
||||||
rpc_restart_call_prepare(struct rpc_task *task)
|
|
||||||
{
|
{
|
||||||
task->tk_action = call_start;
|
|
||||||
task->tk_status = 0;
|
task->tk_status = 0;
|
||||||
if (task->tk_ops->rpc_call_prepare != NULL)
|
task->tk_action = action;
|
||||||
task->tk_action = rpc_prepare_task;
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(rpc_restart_call_prepare);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Restart an (async) RPC call. Usually called from within the
|
* Restart an (async) RPC call. Usually called from within the
|
||||||
@ -1486,12 +1479,23 @@ EXPORT_SYMBOL_GPL(rpc_restart_call_prepare);
|
|||||||
int
|
int
|
||||||
rpc_restart_call(struct rpc_task *task)
|
rpc_restart_call(struct rpc_task *task)
|
||||||
{
|
{
|
||||||
task->tk_action = call_start;
|
return __rpc_restart_call(task, call_start);
|
||||||
task->tk_status = 0;
|
|
||||||
return 1;
|
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(rpc_restart_call);
|
EXPORT_SYMBOL_GPL(rpc_restart_call);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Restart an (async) RPC call from the call_prepare state.
|
||||||
|
* Usually called from within the exit handler.
|
||||||
|
*/
|
||||||
|
int
|
||||||
|
rpc_restart_call_prepare(struct rpc_task *task)
|
||||||
|
{
|
||||||
|
if (task->tk_ops->rpc_call_prepare != NULL)
|
||||||
|
return __rpc_restart_call(task, rpc_prepare_task);
|
||||||
|
return rpc_restart_call(task);
|
||||||
|
}
|
||||||
|
EXPORT_SYMBOL_GPL(rpc_restart_call_prepare);
|
||||||
|
|
||||||
const char
|
const char
|
||||||
*rpc_proc_name(const struct rpc_task *task)
|
*rpc_proc_name(const struct rpc_task *task)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user