From: Chuck Lever <chuck.lever@oracle.com>
To: Anna.Schumaker@netapp.com
Cc: linux-rdma@vger.kernel.org, linux-nfs@vger.kernel.org
Subject: [PATCH v3 17/17] NFS: Fix size of NFSACL SETACL operations
Date: Tue, 26 May 2015 11:53:52 -0400 [thread overview]
Message-ID: <20150526155352.4542.1803.stgit@manet.1015granger.net> (raw)
In-Reply-To: <20150526153926.4542.96409.stgit@manet.1015granger.net>
When encoding the NFSACL SETACL operation, reserve just the estimated
size of the ACL rather than a fixed maximum. This eliminates needless
zero padding on the wire that the server ignores.
Fixes: ee5dc7732bd5 ('NFS: Fix "kernel BUG at fs/nfs/nfs3xdr.c:1338!"')
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
---
fs/nfs/nfs3xdr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/nfs/nfs3xdr.c b/fs/nfs/nfs3xdr.c
index 53852a4..9b04c2e 100644
--- a/fs/nfs/nfs3xdr.c
+++ b/fs/nfs/nfs3xdr.c
@@ -1342,7 +1342,7 @@ static void nfs3_xdr_enc_setacl3args(struct rpc_rqst *req,
if (args->npages != 0)
xdr_write_pages(xdr, args->pages, 0, args->len);
else
- xdr_reserve_space(xdr, NFS_ACL_INLINE_BUFSIZE);
+ xdr_reserve_space(xdr, args->len);
error = nfsacl_encode(xdr->buf, base, args->inode,
(args->mask & NFS_ACL) ?
prev parent reply other threads:[~2015-05-26 15:53 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-26 15:51 [PATCH v3 00/17] NFS/RDMA client patches for 4.2 Chuck Lever
2015-05-26 15:51 ` [PATCH v3 01/17] SUNRPC: Transport fault injection Chuck Lever
2015-05-26 15:51 ` [PATCH v3 02/17] xprtrdma: Warn when there are orphaned IB objects Chuck Lever
2015-05-26 15:51 ` [PATCH v3 03/17] xprtrdma: Replace rpcrdma_rep::rr_buffer with rr_rxprt Chuck Lever
2015-05-26 15:51 ` [PATCH v3 04/17] xprtrdma: Remove rr_func Chuck Lever
2015-05-26 15:51 ` [PATCH v3 05/17] xprtrdma: Use ib_device pointer safely Chuck Lever
2015-05-26 15:52 ` [PATCH v3 06/17] xprtrdma: Introduce helpers for allocating MWs Chuck Lever
2015-05-26 15:52 ` [PATCH v3 07/17] xprtrdma: Acquire FMRs in rpcrdma_fmr_register_external() Chuck Lever
2015-05-26 15:52 ` [PATCH v3 08/17] xprtrdma: Introduce an FRMR recovery workqueue Chuck Lever
2015-05-26 15:52 ` [PATCH v3 09/17] xprtrdma: Acquire MRs in rpcrdma_register_external() Chuck Lever
2015-05-26 15:52 ` [PATCH v3 10/17] xprtrdma: Remove unused LOCAL_INV recovery logic Chuck Lever
2015-05-26 15:52 ` [PATCH v3 11/17] xprtrdma: Remove ->ro_reset Chuck Lever
2015-05-26 15:53 ` [PATCH v3 12/17] xprtrdma: Remove rpcrdma_ia::ri_memreg_strategy Chuck Lever
2015-05-26 15:53 ` [PATCH v3 13/17] xprtrdma: Split rb_lock Chuck Lever
2015-05-26 15:53 ` [PATCH v3 14/17] xprtrdma: Stack relief in fmr_op_map() Chuck Lever
2015-05-26 15:53 ` [PATCH v3 15/17] xprtrdma: Reduce per-transport MR allocation Chuck Lever
2015-05-26 15:53 ` [PATCH v3 16/17] SUNRPC: Clean up bc_send() Chuck Lever
2015-05-26 15:53 ` Chuck Lever [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150526155352.4542.1803.stgit@manet.1015granger.net \
--to=chuck.lever@oracle.com \
--cc=Anna.Schumaker@netapp.com \
--cc=linux-nfs@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).