From: Vivek Goyal <vgoyal@redhat.com>
To: JeffleXu <jefflexu@linux.alibaba.com>
Cc: stefanha@redhat.com, miklos@szeredi.hu,
linux-fsdevel@vger.kernel.org, virtio-fs@redhat.com,
bo.liu@linux.alibaba.com, joseph.qi@linux.alibaba.com
Subject: Re: [PATCH v6 3/7] fuse: support per-file DAX in fuse protocol
Date: Wed, 20 Oct 2021 10:54:15 -0400 [thread overview]
Message-ID: <YXAtlz7eM3xkMjH3@redhat.com> (raw)
In-Reply-To: <c5d98a2c-7fe6-47a8-443d-4c4eed02d97a@linux.alibaba.com>
On Wed, Oct 20, 2021 at 11:04:03AM +0800, JeffleXu wrote:
>
>
> On 10/18/21 10:20 PM, Vivek Goyal wrote:
> > On Mon, Oct 18, 2021 at 10:14:04AM -0400, Vivek Goyal wrote:
> >> On Mon, Oct 11, 2021 at 11:00:48AM +0800, Jeffle Xu wrote:
> >>> Expand the fuse protocol to support per-file DAX.
> >>>
> >>> FUSE_PERFILE_DAX flag is added indicating if fuse server/client
> >>
> >> Should we call this flag FUSE_INODE_DAX instead? It is per inode property?
> >>
>
> Yes, strictly specking, 'per-file' is not correct.
>
> >
> > I realized that you are using FUSE_DAX_INODE to represent dax mode. So it
> > will be confusing to use FUSE_INODE_DAX as protocol flag. How about
> > FUSE_INODE_DAX_STATE instead?
> >
>
> Emmm, the "_STATE" suffix is not straightforward and clear to me. How
> about FUSE_HAS_INODE_DAX or FUSE_DO_INODE_DAX, referring to the existing
> 'FUSE_HAS_IOCTL_DIR' and 'FUSE_DO_READDIRPLUS'?
FUSE_HAS_INODE_DAX or FUSE_DO_INODE_DAX are fine.
Vivek
>
>
> >>
> >>> supporting per-file DAX. It can be conveyed in both FUSE_INIT request
> >>> and reply.
> >>>
> >>> FUSE_ATTR_DAX flag is added indicating if DAX shall be enabled for
> >>> corresponding file. It is conveyed in FUSE_LOOKUP reply.
> >>>
> >>> Signed-off-by: Jeffle Xu <jefflexu@linux.alibaba.com>
> >>> ---
> >>> include/uapi/linux/fuse.h | 9 ++++++++-
> >>> 1 file changed, 8 insertions(+), 1 deletion(-)
> >>>
> >>> diff --git a/include/uapi/linux/fuse.h b/include/uapi/linux/fuse.h
> >>> index 36ed092227fa..15a1f5fc0797 100644
> >>> --- a/include/uapi/linux/fuse.h
> >>> +++ b/include/uapi/linux/fuse.h
> >>> @@ -184,6 +184,9 @@
> >>> *
> >>> * 7.34
> >>> * - add FUSE_SYNCFS
> >>> + *
> >>> + * 7.35
> >>> + * - add FUSE_PERFILE_DAX, FUSE_ATTR_DAX
> >>> */
> >>>
> >>> #ifndef _LINUX_FUSE_H
> >>> @@ -219,7 +222,7 @@
> >>> #define FUSE_KERNEL_VERSION 7
> >>>
> >>> /** Minor version number of this interface */
> >>> -#define FUSE_KERNEL_MINOR_VERSION 34
> >>> +#define FUSE_KERNEL_MINOR_VERSION 35
> >>>
> >>> /** The node ID of the root inode */
> >>> #define FUSE_ROOT_ID 1
> >>> @@ -336,6 +339,7 @@ struct fuse_file_lock {
> >>> * write/truncate sgid is killed only if file has group
> >>> * execute permission. (Same as Linux VFS behavior).
> >>> * FUSE_SETXATTR_EXT: Server supports extended struct fuse_setxattr_in
> >>> + * FUSE_PERFILE_DAX: kernel supports per-file DAX
> >>> */
> >>> #define FUSE_ASYNC_READ (1 << 0)
> >>> #define FUSE_POSIX_LOCKS (1 << 1)
> >>> @@ -367,6 +371,7 @@ struct fuse_file_lock {
> >>> #define FUSE_SUBMOUNTS (1 << 27)
> >>> #define FUSE_HANDLE_KILLPRIV_V2 (1 << 28)
> >>> #define FUSE_SETXATTR_EXT (1 << 29)
> >>> +#define FUSE_PERFILE_DAX (1 << 30)
> >>>
> >>> /**
> >>> * CUSE INIT request/reply flags
> >>> @@ -449,8 +454,10 @@ struct fuse_file_lock {
> >>> * fuse_attr flags
> >>> *
> >>> * FUSE_ATTR_SUBMOUNT: Object is a submount root
> >>> + * FUSE_ATTR_DAX: Enable DAX for this file in per-file DAX mode
> >>> */
> >>> #define FUSE_ATTR_SUBMOUNT (1 << 0)
> >>> +#define FUSE_ATTR_DAX (1 << 1)
> >>>
> >>> /**
> >>> * Open flags
> >>> --
> >>> 2.27.0
> >>>
>
> --
> Thanks,
> Jeffle
>
next prev parent reply other threads:[~2021-10-20 14:54 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-11 3:00 [PATCH v6 0/7] fuse,virtiofs: support per-file DAX Jeffle Xu
2021-10-11 3:00 ` [PATCH v6 1/7] fuse: add fuse_should_enable_dax() helper Jeffle Xu
2021-10-11 3:00 ` [PATCH v6 2/7] fuse: make DAX mount option a tri-state Jeffle Xu
2021-10-18 14:10 ` Vivek Goyal
2021-10-20 2:52 ` JeffleXu
2021-10-20 14:48 ` Vivek Goyal
2021-10-29 8:33 ` JeffleXu
2021-10-29 13:03 ` Vivek Goyal
2021-11-01 8:21 ` JeffleXu
2021-10-20 15:17 ` Vivek Goyal
2021-10-22 6:54 ` JeffleXu
2021-10-25 17:52 ` Ira Weiny
2021-10-25 18:12 ` Vivek Goyal
2021-10-25 19:02 ` Ira Weiny
2021-10-25 19:33 ` Vivek Goyal
2021-10-25 20:41 ` Ira Weiny
2021-10-26 13:45 ` Vivek Goyal
2021-10-27 6:00 ` JeffleXu
2021-10-11 3:00 ` [PATCH v6 3/7] fuse: support per-file DAX in fuse protocol Jeffle Xu
2021-10-18 14:14 ` Vivek Goyal
2021-10-18 14:20 ` Vivek Goyal
2021-10-20 3:04 ` JeffleXu
2021-10-20 14:54 ` Vivek Goyal [this message]
2021-10-11 3:00 ` [PATCH v6 4/7] fuse: negotiate per-file DAX in FUSE_INIT Jeffle Xu
2021-10-18 14:30 ` Vivek Goyal
2021-10-20 3:10 ` JeffleXu
2021-10-20 15:44 ` Vivek Goyal
2021-10-11 3:00 ` [PATCH v6 5/7] fuse: enable per-file DAX Jeffle Xu
2021-10-18 15:11 ` Vivek Goyal
2021-10-11 3:00 ` [PATCH v6 6/7] fuse: mark inode DONT_CACHE when per-file DAX hint changes Jeffle Xu
2021-10-18 15:19 ` Vivek Goyal
2021-10-27 5:05 ` JeffleXu
2021-10-11 3:00 ` [PATCH v6 7/7] Documentation/filesystem/dax: record DAX on virtiofs Jeffle Xu
2021-10-15 3:33 ` [PATCH v6 0/7] fuse,virtiofs: support per-file DAX JeffleXu
2021-10-18 15:21 ` Vivek Goyal
2021-10-20 5:22 ` JeffleXu
2021-10-20 16:06 ` Vivek Goyal
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=YXAtlz7eM3xkMjH3@redhat.com \
--to=vgoyal@redhat.com \
--cc=bo.liu@linux.alibaba.com \
--cc=jefflexu@linux.alibaba.com \
--cc=joseph.qi@linux.alibaba.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=miklos@szeredi.hu \
--cc=stefanha@redhat.com \
--cc=virtio-fs@redhat.com \
/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).