aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/nfs4state.c
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2009-12-05 19:32:19 -0500
committerTrond Myklebust <Trond.Myklebust@netapp.com>2009-12-05 19:32:19 -0500
commit35dc1d74a8d97a302a202ccb6751bf2bdbf5173e (patch)
tree0791d69bc97fac30b9f52e7f96479e31386bb6f8 /fs/nfs/nfs4state.c
parentd61e612a728fb9bf848c4383f8f6645e822d5b57 (diff)
NFSv41: Fix up some bugs in the NFS4CLNT_SESSION_DRAINING code
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/nfs4state.c')
-rw-r--r--fs/nfs/nfs4state.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/nfs/nfs4state.c b/fs/nfs/nfs4state.c
index 37f020eb92f2..ef9622e500e4 100644
--- a/fs/nfs/nfs4state.c
+++ b/fs/nfs/nfs4state.c
@@ -1220,10 +1220,10 @@ static int nfs4_reset_session(struct nfs_client *clp)
1220 struct nfs4_slot_table *tbl = &ses->fc_slot_table; 1220 struct nfs4_slot_table *tbl = &ses->fc_slot_table;
1221 int status; 1221 int status;
1222 1222
1223 INIT_COMPLETION(ses->complete);
1224 spin_lock(&tbl->slot_tbl_lock); 1223 spin_lock(&tbl->slot_tbl_lock);
1225 set_bit(NFS4CLNT_SESSION_DRAINING, &clp->cl_state); 1224 set_bit(NFS4CLNT_SESSION_DRAINING, &clp->cl_state);
1226 if (tbl->highest_used_slotid != -1) { 1225 if (tbl->highest_used_slotid != -1) {
1226 INIT_COMPLETION(ses->complete);
1227 spin_unlock(&tbl->slot_tbl_lock); 1227 spin_unlock(&tbl->slot_tbl_lock);
1228 status = wait_for_completion_interruptible(&ses->complete); 1228 status = wait_for_completion_interruptible(&ses->complete);
1229 if (status) /* -ERESTARTSYS */ 1229 if (status) /* -ERESTARTSYS */
@@ -1247,7 +1247,7 @@ static int nfs4_reset_session(struct nfs_client *clp)
1247out: 1247out:
1248 /* Wake up the next rpc task even on error */ 1248 /* Wake up the next rpc task even on error */
1249 clear_bit(NFS4CLNT_SESSION_DRAINING, &clp->cl_state); 1249 clear_bit(NFS4CLNT_SESSION_DRAINING, &clp->cl_state);
1250 rpc_wake_up_next(&clp->cl_session->fc_slot_table.slot_tbl_waitq); 1250 rpc_wake_up(&clp->cl_session->fc_slot_table.slot_tbl_waitq);
1251 return status; 1251 return status;
1252} 1252}
1253 1253