summaryrefslogtreecommitdiff
path: root/fs/nfsd/nfs4state.c
diff options
context:
space:
mode:
authorJ. Bruce Fields <bfields@citi.umich.edu>2010-03-04 19:32:59 +0300
committerJ. Bruce Fields <bfields@citi.umich.edu>2010-04-22 19:34:02 +0400
commitb12a05cbdfdf7e4d8cbe8fa78e995f971420086b (patch)
tree05f82bd2abf8ab0b688383c467b76db713cdcc09 /fs/nfsd/nfs4state.c
parentb5a1a81e5c25fb6bb3fdc1812ba69ff6ab638fcf (diff)
downloadlinux-b12a05cbdfdf7e4d8cbe8fa78e995f971420086b.tar.xz
nfsd4: cl_count is unused
Now that the shutdown sequence guarantees callbacks are shut down before the client is destroyed, we no longer have a use for cl_count. We'll probably reinstate a reference count on the client some day, but it will be held by users other than callbacks. Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Diffstat (limited to 'fs/nfsd/nfs4state.c')
-rw-r--r--fs/nfsd/nfs4state.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index adc51d10d435..cf650cbb814b 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -690,13 +690,6 @@ free_client(struct nfs4_client *clp)
kfree(clp);
}
-void
-put_nfs4_client(struct nfs4_client *clp)
-{
- if (atomic_dec_and_test(&clp->cl_count))
- free_client(clp);
-}
-
static void
expire_client(struct nfs4_client *clp)
{
@@ -735,7 +728,7 @@ expire_client(struct nfs4_client *clp)
nfsd4_set_callback_client(clp, NULL);
if (clp->cl_cb_xprt)
svc_xprt_put(clp->cl_cb_xprt);
- put_nfs4_client(clp);
+ free_client(clp);
}
static void copy_verf(struct nfs4_client *target, nfs4_verifier *source)
@@ -821,7 +814,6 @@ static struct nfs4_client *create_client(struct xdr_netobj name, char *recdir,
}
memcpy(clp->cl_recdir, recdir, HEXDIR_LEN);
- atomic_set(&clp->cl_count, 1);
atomic_set(&clp->cl_cb_conn.cb_set, 0);
INIT_LIST_HEAD(&clp->cl_idhash);
INIT_LIST_HEAD(&clp->cl_strhash);
@@ -2010,7 +2002,6 @@ void nfsd_break_deleg_cb(struct file_lock *fl)
* lock) we know the server hasn't removed the lease yet, we know
* it's safe to take a reference: */
atomic_inc(&dp->dl_count);
- atomic_inc(&dp->dl_client->cl_count);
spin_lock(&recall_lock);
list_add_tail(&dp->dl_recall_lru, &del_recall_lru);