|
@@ -1255,14 +1255,16 @@ int nfs4_wait_clnt_recover(struct nfs_client *clp)
|
|
|
|
|
|
might_sleep();
|
|
might_sleep();
|
|
|
|
|
|
|
|
+ atomic_inc(&clp->cl_count);
|
|
res = wait_on_bit(&clp->cl_state, NFS4CLNT_MANAGER_RUNNING,
|
|
res = wait_on_bit(&clp->cl_state, NFS4CLNT_MANAGER_RUNNING,
|
|
nfs_wait_bit_killable, TASK_KILLABLE);
|
|
nfs_wait_bit_killable, TASK_KILLABLE);
|
|
if (res)
|
|
if (res)
|
|
- return res;
|
|
|
|
-
|
|
|
|
|
|
+ goto out;
|
|
if (clp->cl_cons_state < 0)
|
|
if (clp->cl_cons_state < 0)
|
|
- return clp->cl_cons_state;
|
|
|
|
- return 0;
|
|
|
|
|
|
+ res = clp->cl_cons_state;
|
|
|
|
+out:
|
|
|
|
+ nfs_put_client(clp);
|
|
|
|
+ return res;
|
|
}
|
|
}
|
|
|
|
|
|
int nfs4_client_recover_expired_lease(struct nfs_client *clp)
|
|
int nfs4_client_recover_expired_lease(struct nfs_client *clp)
|