diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2008-03-12 23:20:55 +0300 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2008-03-14 20:42:35 +0300 |
commit | 4ccda2cdd8d156b6f49440653d5d6997e0facf97 (patch) | |
tree | fd75203f002edfd1657c9ca7bcb5494a7b783cf1 /net/sunrpc/sched.c | |
parent | af093835774931de898a9baf7b4041fa0d100f77 (diff) | |
download | linux-4ccda2cdd8d156b6f49440653d5d6997e0facf97.tar.xz |
SUNRPC: Clean up rpcauth_bindcred()
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net/sunrpc/sched.c')
-rw-r--r-- | net/sunrpc/sched.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c index 7db956f6e018..6eab9bf94baf 100644 --- a/net/sunrpc/sched.c +++ b/net/sunrpc/sched.c @@ -817,14 +817,11 @@ static void rpc_init_task(struct rpc_task *task, const struct rpc_task_setup *ta task->tk_action = rpc_prepare_task; if (task_setup_data->rpc_message != NULL) { - memcpy(&task->tk_msg, task_setup_data->rpc_message, sizeof(task->tk_msg)); + task->tk_msg.rpc_proc = task_setup_data->rpc_message->rpc_proc; + task->tk_msg.rpc_argp = task_setup_data->rpc_message->rpc_argp; + task->tk_msg.rpc_resp = task_setup_data->rpc_message->rpc_resp; /* Bind the user cred */ - if (task->tk_msg.rpc_cred != NULL) - rpcauth_holdcred(task); - else if (!(task_setup_data->flags & RPC_TASK_ROOTCREDS)) - rpcauth_bindcred(task); - else - rpcauth_bind_root_cred(task); + rpcauth_bindcred(task, task_setup_data->rpc_message->rpc_cred, task_setup_data->flags); if (task->tk_action == NULL) rpc_call_start(task); } |