]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
NFSD: Reorder the fields in struct nfsd4_op
authorChuck Lever <chuck.lever@oracle.com>
Wed, 27 Jul 2022 18:40:28 +0000 (14:40 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 10 Apr 2024 14:19:13 +0000 (16:19 +0200)
[ Upstream commit d314309425ad5dc1b6facdb2d456580fb5fa5e3a ]

Pack the fields to reduce the size of struct nfsd4_op, which is used
an array in struct nfsd4_compoundargs.

sizeof(struct nfsd4_op):
Before: /* size: 672, cachelines: 11, members: 5 */
After:  /* size: 640, cachelines: 10, members: 5 */

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
fs/nfsd/xdr4.h

index ed90843a55293418de5966709450ecafc3cb0544..87b4270af59ef2abe1e66b7554224b5fb66b55c2 100644 (file)
@@ -606,8 +606,9 @@ struct nfsd4_copy_notify {
 
 struct nfsd4_op {
        u32                                     opnum;
-       const struct nfsd4_operation *          opdesc;
        __be32                                  status;
+       const struct nfsd4_operation            *opdesc;
+       struct nfs4_replay                      *replay;
        union nfsd4_op_u {
                struct nfsd4_access             access;
                struct nfsd4_close              close;
@@ -671,7 +672,6 @@ struct nfsd4_op {
                struct nfsd4_listxattrs         listxattrs;
                struct nfsd4_removexattr        removexattr;
        } u;
-       struct nfs4_replay *                    replay;
 };
 
 bool nfsd4_cache_this_op(struct nfsd4_op *);