RPC: The RPCAUTH_CRED_DEAD flag had been unused for some time before I unwisely revived it for use with the gss code. Having removed that use from the gss code, it's time to remove all references to it. Signed-off-by: J. Bruce Fields Signed-off-by: Trond Myklebust --- linux-2.6.9-rc2-bfields/include/linux/sunrpc/auth.h | 2 -- linux-2.6.9-rc2-bfields/net/sunrpc/auth.c | 12 ------------ 2 files changed, 14 deletions(-) diff -puN include/linux/sunrpc/auth.h~rpcauth_remove_obsolete_flag include/linux/sunrpc/auth.h --- linux-2.6.9-rc2/include/linux/sunrpc/auth.h~rpcauth_remove_obsolete_flag 2004-09-14 11:09:41.000000000 -0400 +++ linux-2.6.9-rc2-bfields/include/linux/sunrpc/auth.h 2004-09-14 11:09:41.000000000 -0400 @@ -51,7 +51,6 @@ struct rpc_cred { }; #define RPCAUTH_CRED_LOCKED 0x0001 #define RPCAUTH_CRED_UPTODATE 0x0002 -#define RPCAUTH_CRED_DEAD 0x0004 #define RPCAUTH_CRED_MAGIC 0x0f4aa4f0 @@ -133,7 +132,6 @@ int rpcauth_unwrap_resp(struct rpc_tas int rpcauth_refreshcred(struct rpc_task *); void rpcauth_invalcred(struct rpc_task *); int rpcauth_uptodatecred(struct rpc_task *); -int rpcauth_deadcred(struct rpc_task *); void rpcauth_init_credcache(struct rpc_auth *); void rpcauth_free_credcache(struct rpc_auth *); diff -puN net/sunrpc/auth.c~rpcauth_remove_obsolete_flag net/sunrpc/auth.c --- linux-2.6.9-rc2/net/sunrpc/auth.c~rpcauth_remove_obsolete_flag 2004-09-14 11:09:41.000000000 -0400 +++ linux-2.6.9-rc2-bfields/net/sunrpc/auth.c 2004-09-14 11:09:41.000000000 -0400 @@ -214,8 +214,6 @@ retry: list_for_each_safe(pos, next, &auth->au_credcache[nr]) { struct rpc_cred *entry; entry = list_entry(pos, struct rpc_cred, cr_hash); - if (entry->cr_flags & RPCAUTH_CRED_DEAD) - continue; if (rpcauth_prune_expired(entry, &free)) continue; if (entry->cr_ops->crmatch(acred, entry, taskflags)) { @@ -307,9 +305,6 @@ put_rpccred(struct rpc_cred *cred) if (!atomic_dec_and_lock(&cred->cr_count, &rpc_credcache_lock)) return; - if ((cred->cr_flags & RPCAUTH_CRED_DEAD) && !list_empty(&cred->cr_hash)) - list_del_init(&cred->cr_hash); - if (list_empty(&cred->cr_hash)) { spin_unlock(&rpc_credcache_lock); rpcauth_crdestroy(cred); @@ -413,10 +408,3 @@ rpcauth_uptodatecred(struct rpc_task *ta return !(task->tk_msg.rpc_cred) || (task->tk_msg.rpc_cred->cr_flags & RPCAUTH_CRED_UPTODATE); } - -int -rpcauth_deadcred(struct rpc_task *task) -{ - return !(task->tk_msg.rpc_cred) || - (task->tk_msg.rpc_cred->cr_flags & RPCAUTH_CRED_DEAD); -} _