Skip to content

Commit 9993a66

Browse files
committed
NFSD: Clean up nfs4svc_encode_compoundres()
In today's Linux NFS server implementation, the NFS dispatcher initializes each XDR result stream, and the NFSv4 .pc_func and .pc_encode methods all use xdr_stream-based encoding. This keeps rq_res.len automatically updated. There is no longer a need for the WARN_ON_ONCE() check in nfs4svc_encode_compoundres(). Reviewed-by: Jeff Layton <jlayton@kernel.org> Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
1 parent b8ab2a6 commit 9993a66

1 file changed

Lines changed: 0 additions & 4 deletions

File tree

fs/nfsd/nfs4xdr.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5459,12 +5459,8 @@ bool
54595459
nfs4svc_encode_compoundres(struct svc_rqst *rqstp, struct xdr_stream *xdr)
54605460
{
54615461
struct nfsd4_compoundres *resp = rqstp->rq_resp;
5462-
struct xdr_buf *buf = xdr->buf;
54635462
__be32 *p;
54645463

5465-
WARN_ON_ONCE(buf->len != buf->head[0].iov_len + buf->page_len +
5466-
buf->tail[0].iov_len);
5467-
54685464
/*
54695465
* Send buffer space for the following items is reserved
54705466
* at the top of nfsd4_proc_compound().

0 commit comments

Comments
 (0)