diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-02-01 12:18:36 -0500 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-02-01 12:52:23 -0500 |
commit | 8a3177604b729ec3b80e43790ee978863ac7551b (patch) | |
tree | 6eeafbdae55e2b0821e524f2c16bca52fa150cdc /include | |
parent | aaaa99423b4b1f9cfd33ea5643d9274c25f62491 (diff) |
SUNRPC: Fix a lock recursion in the auth_gss downcall
When we look up a new cred in the auth_gss downcall so that we can stuff
the credcache, we do not want that lookup to queue up an upcall in order
to initialise it. To do an upcall here not only redundant, but since we
are already holding the inode->i_mutex, it will trigger a lock recursion.
This patch allows rpcauth cache searches to indicate that they can cope
with uninitialised credentials.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/sunrpc/auth.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/sunrpc/auth.h b/include/linux/sunrpc/auth.h index b68c11a2d6d..bfc5fb27953 100644 --- a/include/linux/sunrpc/auth.h +++ b/include/linux/sunrpc/auth.h | |||
@@ -50,6 +50,7 @@ struct rpc_cred { | |||
50 | }; | 50 | }; |
51 | #define RPCAUTH_CRED_LOCKED 0x0001 | 51 | #define RPCAUTH_CRED_LOCKED 0x0001 |
52 | #define RPCAUTH_CRED_UPTODATE 0x0002 | 52 | #define RPCAUTH_CRED_UPTODATE 0x0002 |
53 | #define RPCAUTH_CRED_NEW 0x0004 | ||
53 | 54 | ||
54 | #define RPCAUTH_CRED_MAGIC 0x0f4aa4f0 | 55 | #define RPCAUTH_CRED_MAGIC 0x0f4aa4f0 |
55 | 56 | ||
@@ -87,6 +88,10 @@ struct rpc_auth { | |||
87 | * uid/gid, fs[ug]id, gids) | 88 | * uid/gid, fs[ug]id, gids) |
88 | */ | 89 | */ |
89 | 90 | ||
91 | /* Flags for rpcauth_lookupcred() */ | ||
92 | #define RPCAUTH_LOOKUP_NEW 0x01 /* Accept an uninitialised cred */ | ||
93 | #define RPCAUTH_LOOKUP_ROOTCREDS 0x02 /* This really ought to go! */ | ||
94 | |||
90 | /* | 95 | /* |
91 | * Client authentication ops | 96 | * Client authentication ops |
92 | */ | 97 | */ |