summaryrefslogtreecommitdiffstats
path: root/net/sunrpc/sched.c
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2008-03-12 12:12:16 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2008-03-14 13:42:32 -0400
commitaf093835774931de898a9baf7b4041fa0d100f77 (patch)
treef7617eb4556ead8615f6c26d8b02fcec8f64c6b3 /net/sunrpc/sched.c
parent25337fdc85951dfeac944f16cb565904c619077a (diff)
downloadlinux-af093835774931de898a9baf7b4041fa0d100f77.tar.bz2
SUNRPC: Fix RPCAUTH_LOOKUP_ROOTCREDS
The current RPCAUTH_LOOKUP_ROOTCREDS flag only works for AUTH_SYS authentication, and then only as a special case in the code. This patch removes the auth_sys special casing, and replaces it with generic code. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net/sunrpc/sched.c')
-rw-r--r--net/sunrpc/sched.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c
index cae219c8caeb..7db956f6e018 100644
--- a/net/sunrpc/sched.c
+++ b/net/sunrpc/sched.c
@@ -821,8 +821,10 @@ static void rpc_init_task(struct rpc_task *task, const struct rpc_task_setup *ta
/* Bind the user cred */
if (task->tk_msg.rpc_cred != NULL)
rpcauth_holdcred(task);
- else
+ else if (!(task_setup_data->flags & RPC_TASK_ROOTCREDS))
rpcauth_bindcred(task);
+ else
+ rpcauth_bind_root_cred(task);
if (task->tk_action == NULL)
rpc_call_start(task);
}