diff options
author | Vivek Goyal <vgoyal@redhat.com> | 2020-08-20 01:19:47 +0300 |
---|---|---|
committer | Miklos Szeredi <mszeredi@redhat.com> | 2020-09-10 12:39:22 +0300 |
commit | 1dd539577c42b67da796e2e758e04171bb889779 (patch) | |
tree | ec3e67b9b630f9803c9f01d8ebaabb9a9db3ea1d /fs/fuse/fuse_i.h | |
parent | 22f3787e9d95e72d1f09795f294fb010e2998f43 (diff) | |
download | linux-1dd539577c42b67da796e2e758e04171bb889779.tar.xz |
virtiofs: add a mount option to enable dax
Add a mount option to allow using dax with virtio_fs.
Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'fs/fuse/fuse_i.h')
-rw-r--r-- | fs/fuse/fuse_i.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h index 30737aabd932..97af7952373a 100644 --- a/fs/fuse/fuse_i.h +++ b/fs/fuse/fuse_i.h @@ -483,10 +483,14 @@ struct fuse_fs_context { bool no_control:1; bool no_force_umount:1; bool legacy_opts_show:1; + bool dax:1; unsigned int max_read; unsigned int blksize; const char *subtype; + /* DAX device, may be NULL */ + struct dax_device *dax_dev; + /* fuse_dev pointer to fill in, should contain NULL on entry */ void **fudptr; }; @@ -755,6 +759,11 @@ struct fuse_conn { /** List of device instances belonging to this connection */ struct list_head devices; + +#ifdef CONFIG_FUSE_DAX + /* Dax specific conn data, non-NULL if DAX is enabled */ + struct fuse_conn_dax *dax; +#endif }; static inline struct fuse_conn *get_fuse_conn_super(struct super_block *sb) @@ -1093,4 +1102,9 @@ unsigned int fuse_len_args(unsigned int numargs, struct fuse_arg *args); u64 fuse_get_unique(struct fuse_iqueue *fiq); void fuse_free_conn(struct fuse_conn *fc); +/* dax.c */ + +int fuse_dax_conn_alloc(struct fuse_conn *fc, struct dax_device *dax_dev); +void fuse_dax_conn_free(struct fuse_conn *fc); + #endif /* _FS_FUSE_I_H */ |