From 11ab4e4a33e3795f83edab16b97ad99c25dc60ab Mon Sep 17 00:00:00 2001 From: Alexandros Batsakis Date: Fri, 5 Feb 2010 03:45:06 -0800 Subject: [PATCH] --- yaml --- r: 186155 b: refs/heads/master c: 0851de06174e9800e76b26e4be0ca94294c09c8c h: refs/heads/master i: 186153: b989ccac408abe8667cc0904234258ac4019532e 186151: d976c2d4eb8d3bb2ee7f3fb36c93b95588a1bd4a v: v3 --- [refs] | 2 +- trunk/fs/nfs/nfs4proc.c | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 63a74da7ebfe..718f0bf46f5d 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 7135840fc74699513d50e0c9c64922f2d38aa5e3 +refs/heads/master: 0851de06174e9800e76b26e4be0ca94294c09c8c diff --git a/trunk/fs/nfs/nfs4proc.c b/trunk/fs/nfs/nfs4proc.c index 663ae0c36834..68f1fe00c08c 100644 --- a/trunk/fs/nfs/nfs4proc.c +++ b/trunk/fs/nfs/nfs4proc.c @@ -3152,7 +3152,9 @@ static void nfs4_renew_release(void *data) { struct nfs_client *clp = data; - nfs4_schedule_state_renewal(clp); + if (atomic_read(&clp->cl_count) > 1) + nfs4_schedule_state_renewal(clp); + nfs_put_client(clp); } static void nfs4_renew_done(struct rpc_task *task, void *data) @@ -3185,6 +3187,8 @@ int nfs4_proc_async_renew(struct nfs_client *clp, struct rpc_cred *cred) .rpc_cred = cred, }; + if (!atomic_inc_not_zero(&clp->cl_count)) + return -EIO; return rpc_call_async(clp->cl_rpcclient, &msg, RPC_TASK_SOFT, &nfs4_renew_ops, clp); }