Skip to content

Commit 702d8d6

Browse files
sbashirogregkh
authored andcommitted
NFSD: Minor cleanup in layoutcommit processing
[ Upstream commit 274365a ] Remove dprintk in nfsd4_layoutcommit. These are not needed in day to day usage, and the information is also available in Wireshark when capturing NFS traffic. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Sergey Bashirov <sergeybashirov@gmail.com> Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Stable-dep-of: d68886b ("NFSD: Fix last write offset handling in layoutcommit") Signed-off-by: Sasha Levin <sashal@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent a39ae0d commit 702d8d6

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

fs/nfsd/nfs4proc.c

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1717,18 +1717,12 @@ nfsd4_layoutcommit(struct svc_rqst *rqstp,
17171717
inode = d_inode(current_fh->fh_dentry);
17181718

17191719
nfserr = nfserr_inval;
1720-
if (new_size <= seg->offset) {
1721-
dprintk("pnfsd: last write before layout segment\n");
1720+
if (new_size <= seg->offset)
17221721
goto out;
1723-
}
1724-
if (new_size > seg->offset + seg->length) {
1725-
dprintk("pnfsd: last write beyond layout segment\n");
1722+
if (new_size > seg->offset + seg->length)
17261723
goto out;
1727-
}
1728-
if (!lcp->lc_newoffset && new_size > i_size_read(inode)) {
1729-
dprintk("pnfsd: layoutcommit beyond EOF\n");
1724+
if (!lcp->lc_newoffset && new_size > i_size_read(inode))
17301725
goto out;
1731-
}
17321726

17331727
nfserr = nfsd4_preprocess_layout_stateid(rqstp, cstate, &lcp->lc_sid,
17341728
false, lcp->lc_layout_type,

0 commit comments

Comments
 (0)