All of lore.kernel.org
 help / color / mirror / Atom feed
* [Virtio-fs] [PATCH 0/2] virtio-fs: fuse.h cleanups
@ 2019-07-25 14:20 Stefan Hajnoczi
  2019-07-25 14:20 ` [Virtio-fs] [PATCH 1/2] fuse: drop unused struct fuse_setupmapping_out Stefan Hajnoczi
  2019-07-25 14:20 ` [Virtio-fs] [PATCH 2/2] fuse: make FUSE_REMOVEMAPPING_MAX_ENTRY private Stefan Hajnoczi
  0 siblings, 2 replies; 3+ messages in thread
From: Stefan Hajnoczi @ 2019-07-25 14:20 UTC (permalink / raw)
  To: virtio-fs

These are minor fixes that should be squashed down for the virtio-fs patch
series being sent upstream.

Stefan Hajnoczi (2):
  fuse: drop unused struct fuse_setupmapping_out
  fuse: make FUSE_REMOVEMAPPING_MAX_ENTRY private

 include/uapi/linux/fuse.h | 11 -----------
 fs/fuse/file.c            |  3 +++
 2 files changed, 3 insertions(+), 11 deletions(-)

-- 
2.21.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Virtio-fs] [PATCH 1/2] fuse: drop unused struct fuse_setupmapping_out
  2019-07-25 14:20 [Virtio-fs] [PATCH 0/2] virtio-fs: fuse.h cleanups Stefan Hajnoczi
@ 2019-07-25 14:20 ` Stefan Hajnoczi
  2019-07-25 14:20 ` [Virtio-fs] [PATCH 2/2] fuse: make FUSE_REMOVEMAPPING_MAX_ENTRY private Stefan Hajnoczi
  1 sibling, 0 replies; 3+ messages in thread
From: Stefan Hajnoczi @ 2019-07-25 14:20 UTC (permalink / raw)
  To: virtio-fs

Originally the idea was that FUSE_SETUPMAPPING returns a list of
addresses where the mmaps were made.  But then we decided to let the
FUSE client decide where to map so it already knows the address.
Consequently this struct is unused.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
 include/uapi/linux/fuse.h | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/include/uapi/linux/fuse.h b/include/uapi/linux/fuse.h
index 562a36add1e2..8c36aadb6294 100644
--- a/include/uapi/linux/fuse.h
+++ b/include/uapi/linux/fuse.h
@@ -824,7 +824,6 @@ struct fuse_copy_file_range_in {
 	uint64_t	flags;
 };
 
-#define FUSE_SETUPMAPPING_ENTRIES 8
 #define FUSE_SETUPMAPPING_FLAG_WRITE (1ull << 0)
 #define FUSE_SETUPMAPPING_FLAG_READ (1ull << 1)
 struct fuse_setupmapping_in {
@@ -840,13 +839,6 @@ struct fuse_setupmapping_in {
 	uint64_t	moffset;
 };
 
-struct fuse_setupmapping_out {
-	/* Offsets into the cache of mappings */
-	uint64_t	coffset[FUSE_SETUPMAPPING_ENTRIES];
-        /* Lengths of each mapping */
-        uint64_t	len[FUSE_SETUPMAPPING_ENTRIES];
-};
-
 struct fuse_removemapping_in {
         /* An already open handle */
         uint64_t	fh;
-- 
2.21.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [Virtio-fs] [PATCH 2/2] fuse: make FUSE_REMOVEMAPPING_MAX_ENTRY private
  2019-07-25 14:20 [Virtio-fs] [PATCH 0/2] virtio-fs: fuse.h cleanups Stefan Hajnoczi
  2019-07-25 14:20 ` [Virtio-fs] [PATCH 1/2] fuse: drop unused struct fuse_setupmapping_out Stefan Hajnoczi
@ 2019-07-25 14:20 ` Stefan Hajnoczi
  1 sibling, 0 replies; 3+ messages in thread
From: Stefan Hajnoczi @ 2019-07-25 14:20 UTC (permalink / raw)
  To: virtio-fs

FUSE_REMOVEMAPPING_MAX_ENTRY is only used by fs/fuse/file.c and is not
part of the FUSE protocol.  Do not expose it in the uapi header file.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
 include/uapi/linux/fuse.h | 3 ---
 fs/fuse/file.c            | 3 +++
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/uapi/linux/fuse.h b/include/uapi/linux/fuse.h
index 8c36aadb6294..0f4b69b9c751 100644
--- a/include/uapi/linux/fuse.h
+++ b/include/uapi/linux/fuse.h
@@ -853,7 +853,4 @@ struct fuse_removemapping_one {
         uint64_t	len;
 };
 
-#define FUSE_REMOVEMAPPING_MAX_ENTRY   \
-		(PAGE_SIZE / sizeof(struct fuse_removemapping_one))
-
 #endif /* _LINUX_FUSE_H */
diff --git a/fs/fuse/file.c b/fs/fuse/file.c
index fc40e0f44578..1e890a8491ae 100644
--- a/fs/fuse/file.c
+++ b/fs/fuse/file.c
@@ -22,6 +22,9 @@
 #include <linux/iomap.h>
 #include <linux/interval_tree_generic.h>
 
+#define FUSE_REMOVEMAPPING_MAX_ENTRY   \
+		(PAGE_SIZE / sizeof(struct fuse_removemapping_one))
+
 INTERVAL_TREE_DEFINE(struct fuse_dax_mapping, rb, __u64, __subtree_last,
                      START, LAST, static inline, fuse_dax_interval_tree);
 
-- 
2.21.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-07-25 14:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-25 14:20 [Virtio-fs] [PATCH 0/2] virtio-fs: fuse.h cleanups Stefan Hajnoczi
2019-07-25 14:20 ` [Virtio-fs] [PATCH 1/2] fuse: drop unused struct fuse_setupmapping_out Stefan Hajnoczi
2019-07-25 14:20 ` [Virtio-fs] [PATCH 2/2] fuse: make FUSE_REMOVEMAPPING_MAX_ENTRY private Stefan Hajnoczi

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.