summaryrefslogtreecommitdiff
path: root/fs/nfsd/xdr4.h
diff options
context:
space:
mode:
authorChuck Lever <chuck.lever@oracle.com>2023-09-18 16:57:51 +0300
committerChuck Lever <chuck.lever@oracle.com>2023-10-16 19:44:14 +0300
commit263453d9bb46ad42f03a0f86aafe580f1b0e9291 (patch)
tree68ca0855e87628fa991e23a5d7741ee0a3367152 /fs/nfsd/xdr4.h
parent36ed7e64947756baa69cfad323898b342bf71a02 (diff)
downloadlinux-263453d9bb46ad42f03a0f86aafe580f1b0e9291.tar.xz
NFSD: Add nfsd4_encode_fattr4_change()
Refactor the encoder for FATTR4_CHANGE into a helper. In a subsequent patch, this helper will be called from a bitmask loop. The code is restructured a bit to use the modern xdr_stream flow, and the encoded cinfo value is made const so that callers of the encoders can be passed a const cinfo. Reviewed-by: Jeff Layton <jlayton@kernel.org> Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Diffstat (limited to 'fs/nfsd/xdr4.h')
-rw-r--r--fs/nfsd/xdr4.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/nfsd/xdr4.h b/fs/nfsd/xdr4.h
index 5c3eb3691f8b..d6059b0549f5 100644
--- a/fs/nfsd/xdr4.h
+++ b/fs/nfsd/xdr4.h
@@ -110,6 +110,8 @@ nfsd4_encode_uint64_t(struct xdr_stream *xdr, u64 val)
return nfs_ok;
}
+#define nfsd4_encode_changeid4(x, v) nfsd4_encode_uint64_t(x, v)
+
/**
* nfsd4_encode_opaque_fixed - Encode a fixed-length XDR opaque type result
* @xdr: target XDR stream