提交 6e46d8a9 编写于 作者: J J. Bruce Fields 提交者: Linus Torvalds

[PATCH] knfsd: nfsd4: remove superfluous grace period checks

We're checking nfs_in_grace here a few times when there isn't really any
reason to--bad_stateid is probably the more sensible return value anyway.
Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: NNeil Brown <neilb@suse.de>
Signed-off-by: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 7fc90ec9
...@@ -2070,16 +2070,12 @@ nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int fl ...@@ -2070,16 +2070,12 @@ nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int fl
if (!stateid->si_fileid) { /* delegation stateid */ if (!stateid->si_fileid) { /* delegation stateid */
if(!(dp = find_delegation_stateid(ino, stateid))) { if(!(dp = find_delegation_stateid(ino, stateid))) {
dprintk("NFSD: delegation stateid not found\n"); dprintk("NFSD: delegation stateid not found\n");
if (nfs4_in_grace())
status = nfserr_grace;
goto out; goto out;
} }
stidp = &dp->dl_stateid; stidp = &dp->dl_stateid;
} else { /* open or lock stateid */ } else { /* open or lock stateid */
if (!(stp = find_stateid(stateid, flags))) { if (!(stp = find_stateid(stateid, flags))) {
dprintk("NFSD: open or lock stateid not found\n"); dprintk("NFSD: open or lock stateid not found\n");
if (nfs4_in_grace())
status = nfserr_grace;
goto out; goto out;
} }
if ((flags & CHECK_FH) && nfs4_check_fh(current_fh, stp)) if ((flags & CHECK_FH) && nfs4_check_fh(current_fh, stp))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册