diff options
author | J. Bruce Fields <bfields@redhat.com> | 2013-03-12 10:12:37 -0400 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2013-04-03 11:48:34 -0400 |
commit | 78389046f733564d5c2c94f0b8d6ff0cdae951d9 (patch) | |
tree | ed4317ab1f47f65e03a72eb95e1a82bcb8338e95 /fs/nfsd | |
parent | 491402a7876e91aa491c33f70ed4e86e59f06c8b (diff) |
nfsd4: warn on odd create_session state
This should never happen.
(Note: the comparable case in setclientid_confirm *can* happen, since
updating a client record can result in both confirmed and unconfirmed
records with the same clientid.)
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd')
-rw-r--r-- | fs/nfsd/nfs4state.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index aac878ecabc4..ef7c6222b7c8 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c | |||
@@ -1788,6 +1788,7 @@ nfsd4_create_session(struct svc_rqst *rqstp, | |||
1788 | nfs4_lock_state(); | 1788 | nfs4_lock_state(); |
1789 | unconf = find_unconfirmed_client(&cr_ses->clientid, true, nn); | 1789 | unconf = find_unconfirmed_client(&cr_ses->clientid, true, nn); |
1790 | conf = find_confirmed_client(&cr_ses->clientid, true, nn); | 1790 | conf = find_confirmed_client(&cr_ses->clientid, true, nn); |
1791 | WARN_ON_ONCE(conf && unconf); | ||
1791 | 1792 | ||
1792 | if (conf) { | 1793 | if (conf) { |
1793 | cs_slot = &conf->cl_cs_slot; | 1794 | cs_slot = &conf->cl_cs_slot; |
@@ -2129,6 +2130,7 @@ nfsd4_destroy_clientid(struct svc_rqst *rqstp, struct nfsd4_compound_state *csta | |||
2129 | nfs4_lock_state(); | 2130 | nfs4_lock_state(); |
2130 | unconf = find_unconfirmed_client(&dc->clientid, true, nn); | 2131 | unconf = find_unconfirmed_client(&dc->clientid, true, nn); |
2131 | conf = find_confirmed_client(&dc->clientid, true, nn); | 2132 | conf = find_confirmed_client(&dc->clientid, true, nn); |
2133 | WARN_ON_ONCE(conf && unconf); | ||
2132 | 2134 | ||
2133 | if (conf) { | 2135 | if (conf) { |
2134 | clp = conf; | 2136 | clp = conf; |