diff mbox series

[RFC,07/35] NFSv4.2: define argument and response structures for xattr operations

Message ID 26089a6ab4337ba6b5c39a6633e7cfac0cd12c2f.1568309119.git.fllinden@amazon.com (mailing list archive)
State New, archived
Headers show
Series user xattr support (RFC8276) | expand

Commit Message

Frank van der Linden Aug. 26, 2019, 10:32 p.m. UTC
Define the argument and response structures that will be used for
RFC 8276 extended attribute RPC calls.

Signed-off-by: Frank van der Linden <fllinden@amazon.com>
---
 include/linux/nfs_xdr.h | 61 ++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 60 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h
index f289c024943d..9299a2465c02 100644
--- a/include/linux/nfs_xdr.h
+++ b/include/linux/nfs_xdr.h
@@ -1480,7 +1480,66 @@  struct nfs42_seek_res {
 	u32	sr_eof;
 	u64	sr_offset;
 };
-#endif
+
+#ifdef CONFIG_NFS_V4_XATTR
+struct nfs42_setxattrargs {
+	struct nfs4_sequence_args	seq_args;
+	struct nfs_fh *			fh;
+	const char *			xattr_name;
+	u32				xattr_flags;
+	size_t				xattr_len;
+	struct page **			xattr_pages;
+};
+
+struct nfs42_setxattrres {
+	struct nfs4_sequence_res	seq_res;
+	struct nfs4_change_info		cinfo;
+};
+
+struct nfs42_getxattrargs {
+	struct nfs4_sequence_args 	seq_args;
+	struct nfs_fh *			fh;
+	const char *			xattr_name;
+	size_t				xattr_len;
+	struct page **			xattr_pages;
+};
+
+struct nfs42_getxattrres {
+	struct nfs4_sequence_res	seq_res;
+	size_t				xattr_len;
+};
+
+struct nfs42_listxattrsargs {
+	struct nfs4_sequence_args	seq_args;
+	struct nfs_fh *			fh;
+	u32				count;
+	u64				cookie;
+	struct page **			xattr_pages;
+};
+
+struct nfs42_listxattrsres {
+	struct nfs4_sequence_res	seq_res;
+	struct page *			scratch;
+	void *				xattr_buf;
+	size_t				xattr_len;
+	u64				cookie;
+	bool				eof;
+	size_t				copied;
+};
+
+struct nfs42_removexattrargs {
+	struct nfs4_sequence_args	seq_args;
+	struct nfs_fh *			fh;
+	const char *			xattr_name;
+};
+
+struct nfs42_removexattrres {
+	struct nfs4_sequence_res	seq_res;
+	struct nfs4_change_info		cinfo;
+};
+
+#endif /* CONFIG_NFS_V4_XATTR */
+#endif /* CONFIG_NFS_V4_2 */
 
 struct nfs_page;