Skip to content

Commit c6ff213

Browse files
XanClicMiklos Szeredi
authored andcommitted
fuse: add submount support to <uapi/linux/fuse.h>
- Add fuse_attr.flags - Add FUSE_ATTR_SUBMOUNT This is a flag for fuse_attr.flags that indicates that the given entry resides on a different filesystem than the parent, and as such should have a different st_dev. - Add FUSE_SUBMOUNTS The client sets this flag if it supports automounting directories. Signed-off-by: Max Reitz <mreitz@redhat.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
1 parent d78092e commit c6ff213

1 file changed

Lines changed: 14 additions & 2 deletions

File tree

include/uapi/linux/fuse.h

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,9 @@
172172
* - add FUSE_WRITE_KILL_PRIV flag
173173
* - add FUSE_SETUPMAPPING and FUSE_REMOVEMAPPING
174174
* - add map_alignment to fuse_init_out, add FUSE_MAP_ALIGNMENT flag
175+
*
176+
* 7.32
177+
* - add flags to fuse_attr, add FUSE_ATTR_SUBMOUNT, add FUSE_SUBMOUNTS
175178
*/
176179

177180
#ifndef _LINUX_FUSE_H
@@ -207,7 +210,7 @@
207210
#define FUSE_KERNEL_VERSION 7
208211

209212
/** Minor version number of this interface */
210-
#define FUSE_KERNEL_MINOR_VERSION 31
213+
#define FUSE_KERNEL_MINOR_VERSION 32
211214

212215
/** The node ID of the root inode */
213216
#define FUSE_ROOT_ID 1
@@ -231,7 +234,7 @@ struct fuse_attr {
231234
uint32_t gid;
232235
uint32_t rdev;
233236
uint32_t blksize;
234-
uint32_t padding;
237+
uint32_t flags;
235238
};
236239

237240
struct fuse_kstatfs {
@@ -316,6 +319,7 @@ struct fuse_file_lock {
316319
* FUSE_MAP_ALIGNMENT: init_out.map_alignment contains log2(byte alignment) for
317320
* foffset and moffset fields in struct
318321
* fuse_setupmapping_out and fuse_removemapping_one.
322+
* FUSE_SUBMOUNTS: kernel supports auto-mounting directory submounts
319323
*/
320324
#define FUSE_ASYNC_READ (1 << 0)
321325
#define FUSE_POSIX_LOCKS (1 << 1)
@@ -344,6 +348,7 @@ struct fuse_file_lock {
344348
#define FUSE_NO_OPENDIR_SUPPORT (1 << 24)
345349
#define FUSE_EXPLICIT_INVAL_DATA (1 << 25)
346350
#define FUSE_MAP_ALIGNMENT (1 << 26)
351+
#define FUSE_SUBMOUNTS (1 << 27)
347352

348353
/**
349354
* CUSE INIT request/reply flags
@@ -419,6 +424,13 @@ struct fuse_file_lock {
419424
*/
420425
#define FUSE_FSYNC_FDATASYNC (1 << 0)
421426

427+
/**
428+
* fuse_attr flags
429+
*
430+
* FUSE_ATTR_SUBMOUNT: Object is a submount root
431+
*/
432+
#define FUSE_ATTR_SUBMOUNT (1 << 0)
433+
422434
enum fuse_opcode {
423435
FUSE_LOOKUP = 1,
424436
FUSE_FORGET = 2, /* no reply */

0 commit comments

Comments
 (0)