diff options
author | J. Bruce Fields <bfields@redhat.com> | 2012-05-18 22:23:42 -0400 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2012-05-31 20:30:02 -0400 |
commit | 34b232bb3742dc88eef7352da2ca018f51ac4561 (patch) | |
tree | 469c41eb6e86d9205560c154cdfe3b8a03d33a79 /fs/nfsd | |
parent | 8f9307119d7fb2f2c04fce27aa492d30e7ac4518 (diff) |
nfsd4: merge 3 setclientid cases to 2
Boy, is this simpler.
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd')
-rw-r--r-- | fs/nfsd/nfs4state.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index 1fe06ebf192f..9d7e3eb0f5db 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c | |||
@@ -2195,16 +2195,11 @@ nfsd4_setclientid(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, | |||
2195 | new = create_client(clname, dname, rqstp, &clverifier); | 2195 | new = create_client(clname, dname, rqstp, &clverifier); |
2196 | if (new == NULL) | 2196 | if (new == NULL) |
2197 | goto out; | 2197 | goto out; |
2198 | if (!conf) { | 2198 | if (conf && same_verf(&conf->cl_verifier, &clverifier)) |
2199 | /* case 4: placed first, because it's the normal case */ | ||
2200 | gen_clid(new); | ||
2201 | } else if (same_verf(&conf->cl_verifier, &clverifier)) { | ||
2202 | /* case 1: probable callback update */ | 2199 | /* case 1: probable callback update */ |
2203 | copy_clid(new, conf); | 2200 | copy_clid(new, conf); |
2204 | } else { /* conf && !same_verf(): */ | 2201 | else /* case 4 (new client) or cases 2, 3 (client reboot): */ |
2205 | /* cases 2, 3: probable client reboot: */ | ||
2206 | gen_clid(new); | 2202 | gen_clid(new); |
2207 | } | ||
2208 | /* | 2203 | /* |
2209 | * XXX: we should probably set this at creation time, and check | 2204 | * XXX: we should probably set this at creation time, and check |
2210 | * for consistent minorversion use throughout: | 2205 | * for consistent minorversion use throughout: |