Commit 0c2a498f authored by J. Bruce Fields's avatar J. Bruce Fields

nfsd4: move check_stateid_generation check

No change in behavior.
Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
parent a4455be0
...@@ -2084,6 +2084,9 @@ nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int fl ...@@ -2084,6 +2084,9 @@ nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int fl
goto out; goto out;
} }
stidp = &dp->dl_stateid; stidp = &dp->dl_stateid;
status = check_stateid_generation(stateid, stidp);
if (status)
goto out;
} else { /* open or lock stateid */ } else { /* open or lock stateid */
stp = find_stateid(stateid, flags); stp = find_stateid(stateid, flags);
if (!stp) { if (!stp) {
...@@ -2095,10 +2098,10 @@ nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int fl ...@@ -2095,10 +2098,10 @@ nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int fl
if (!stp->st_stateowner->so_confirmed) if (!stp->st_stateowner->so_confirmed)
goto out; goto out;
stidp = &stp->st_stateid; stidp = &stp->st_stateid;
status = check_stateid_generation(stateid, stidp);
if (status)
goto out;
} }
status = check_stateid_generation(stateid, stidp);
if (status)
goto out;
if (stp) { if (stp) {
status = nfs4_check_openmode(stp, flags); status = nfs4_check_openmode(stp, flags);
if (status) if (status)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment