aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfsd
diff options
context:
space:
mode:
authorJ. Bruce Fields <bfields@redhat.com>2010-12-09 15:52:19 -0500
committerJ. Bruce Fields <bfields@redhat.com>2011-01-11 15:04:11 -0500
commit84f5f7ccc59e628fc8754c0a837fd7e9559711ac (patch)
tree0c735feb7862b45251a74ead6eb9ae789022a04c /fs/nfsd
parenteea4980660bc204bb9d11bb3bf2b1bde5fd5175f (diff)
nfsd4: make sure sequence flags are set after destroy_session
If this loses any backchannel, make sure we have a chance to notice that and set the sequence flags. Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd')
-rw-r--r--fs/nfsd/nfs4callback.c6
-rw-r--r--fs/nfsd/nfs4state.c3
-rw-r--r--fs/nfsd/state.h1
3 files changed, 8 insertions, 2 deletions
diff --git a/fs/nfsd/nfs4callback.c b/fs/nfsd/nfs4callback.c
index d32f49d6ca2c..cb002dce5630 100644
--- a/fs/nfsd/nfs4callback.c
+++ b/fs/nfsd/nfs4callback.c
@@ -589,6 +589,12 @@ void nfsd4_probe_callback(struct nfs4_client *clp)
589 do_probe_callback(clp); 589 do_probe_callback(clp);
590} 590}
591 591
592void nfsd4_probe_callback_sync(struct nfs4_client *clp)
593{
594 nfsd4_probe_callback(clp);
595 flush_workqueue(callback_wq);
596}
597
592void nfsd4_change_callback(struct nfs4_client *clp, struct nfs4_cb_conn *conn) 598void nfsd4_change_callback(struct nfs4_client *clp, struct nfs4_cb_conn *conn)
593{ 599{
594 clp->cl_cb_state = NFSD4_CB_UNKNOWN; 600 clp->cl_cb_state = NFSD4_CB_UNKNOWN;
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index b24f19d4187a..00a50b8ac878 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -1686,8 +1686,7 @@ nfsd4_destroy_session(struct svc_rqst *r,
1686 spin_unlock(&client_lock); 1686 spin_unlock(&client_lock);
1687 1687
1688 nfs4_lock_state(); 1688 nfs4_lock_state();
1689 /* wait for callbacks */ 1689 nfsd4_probe_callback_sync(ses->se_client);
1690 nfsd4_shutdown_callback(ses->se_client);
1691 nfs4_unlock_state(); 1690 nfs4_unlock_state();
1692 1691
1693 nfsd4_del_conns(ses); 1692 nfsd4_del_conns(ses);
diff --git a/fs/nfsd/state.h b/fs/nfsd/state.h
index 32ff615c36f4..4e5bdfd9169c 100644
--- a/fs/nfsd/state.h
+++ b/fs/nfsd/state.h
@@ -464,6 +464,7 @@ extern __be32 nfs4_check_open_reclaim(clientid_t *clid);
464extern void nfs4_free_stateowner(struct kref *kref); 464extern void nfs4_free_stateowner(struct kref *kref);
465extern int set_callback_cred(void); 465extern int set_callback_cred(void);
466extern void nfsd4_probe_callback(struct nfs4_client *clp); 466extern void nfsd4_probe_callback(struct nfs4_client *clp);
467extern void nfsd4_probe_callback_sync(struct nfs4_client *clp);
467extern void nfsd4_change_callback(struct nfs4_client *clp, struct nfs4_cb_conn *); 468extern void nfsd4_change_callback(struct nfs4_client *clp, struct nfs4_cb_conn *);
468extern void nfsd4_do_callback_rpc(struct work_struct *); 469extern void nfsd4_do_callback_rpc(struct work_struct *);
469extern void nfsd4_cb_recall(struct nfs4_delegation *dp); 470extern void nfsd4_cb_recall(struct nfs4_delegation *dp);