diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2008-03-12 16:21:07 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2008-03-14 13:42:41 -0400 |
commit | 5c691044ecbca04dd558fca4c754121689fe1b34 (patch) | |
tree | 7a56b63c44766fcca0d7ac245ce0e19077b6f118 /net/sunrpc/auth.c | |
parent | 9a559efd4199c9812d339e23cc1b6055366b224f (diff) | |
download | linux-5c691044ecbca04dd558fca4c754121689fe1b34.tar.gz linux-5c691044ecbca04dd558fca4c754121689fe1b34.tar.bz2 linux-5c691044ecbca04dd558fca4c754121689fe1b34.zip |
SUNRPC: Add an rpc_credop callback for binding a credential to an rpc_task
We need the ability to treat 'generic' creds specially, since they want to
bind instances of the auth cred instead of binding themselves.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net/sunrpc/auth.c')
-rw-r--r-- | net/sunrpc/auth.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/net/sunrpc/auth.c b/net/sunrpc/auth.c index 012f2a320638..d65dd7940102 100644 --- a/net/sunrpc/auth.c +++ b/net/sunrpc/auth.c @@ -375,13 +375,14 @@ rpcauth_init_cred(struct rpc_cred *cred, const struct auth_cred *acred, } EXPORT_SYMBOL_GPL(rpcauth_init_cred); -static void +void rpcauth_generic_bind_cred(struct rpc_task *task, struct rpc_cred *cred) { task->tk_msg.rpc_cred = get_rpccred(cred); dprintk("RPC: %5u holding %s cred %p\n", task->tk_pid, cred->cr_auth->au_ops->au_name, cred); } +EXPORT_SYMBOL_GPL(rpcauth_generic_bind_cred); static void rpcauth_bind_root_cred(struct rpc_task *task) @@ -421,7 +422,7 @@ void rpcauth_bindcred(struct rpc_task *task, struct rpc_cred *cred, int flags) { if (cred != NULL) - rpcauth_generic_bind_cred(task, cred); + cred->cr_ops->crbind(task, cred); else if (flags & RPC_TASK_ROOTCREDS) rpcauth_bind_root_cred(task); else |