diff options
author | Miklos Szeredi <miklos@szeredi.hu> | 2015-04-23 14:13:18 +0200 |
---|---|---|
committer | Miklos Szeredi <mszeredi@suse.cz> | 2015-04-23 14:13:18 +0200 |
commit | 04ad73fab6ed679941958ed155169ba4146f719e (patch) | |
tree | a61eef60c589a0fb843728993063babf331b7679 | |
parent | 0ecd21258e24fec185c157520435783780a1ad8f (diff) | |
download | fuse-04ad73fab6ed679941958ed155169ba4146f719e.tar.gz |
libfuse: add FUSE_CAP_NO_OPEN_SUPPORT flag to ->init()
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | include/fuse_common.h | 2 | ||||
-rw-r--r-- | include/fuse_kernel.h | 3 | ||||
-rwxr-xr-x | lib/fuse_lowlevel.c | 2 |
4 files changed, 11 insertions, 0 deletions
@@ -1,3 +1,7 @@ +2015-04-23 Miklos Szeredi <miklos@szeredi.hu> + + * libfuse: add FUSE_CAP_NO_OPEN_SUPPORT flag to ->init() + 2015-02-26 Miklos Szeredi <miklos@szeredi.hu> * libfuse: fix fuse_remove_signal_handlers() to properly restore diff --git a/include/fuse_common.h b/include/fuse_common.h index aec4349..28dfc0b 100644 --- a/include/fuse_common.h +++ b/include/fuse_common.h @@ -101,6 +101,7 @@ struct fuse_file_info { * FUSE_CAP_READDIRPLUS_AUTO: adaptive readdirplus * FUSE_CAP_ASYNC_DIO: asynchronous direct I/O submission * FUSE_CAP_WRITEBACK_CACHE: use writeback cache for buffered writes + * FUSE_CAP_NO_OPEN_SUPPORT: support zero-message opens */ #define FUSE_CAP_ASYNC_READ (1 << 0) #define FUSE_CAP_POSIX_LOCKS (1 << 1) @@ -118,6 +119,7 @@ struct fuse_file_info { #define FUSE_CAP_READDIRPLUS_AUTO (1 << 14) #define FUSE_CAP_ASYNC_DIO (1 << 15) #define FUSE_CAP_WRITEBACK_CACHE (1 << 16) +#define FUSE_CAP_NO_OPEN_SUPPORT (1 << 17) /** * Ioctl flags diff --git a/include/fuse_kernel.h b/include/fuse_kernel.h index 40b5ca8..25084a0 100644 --- a/include/fuse_kernel.h +++ b/include/fuse_kernel.h @@ -101,6 +101,7 @@ * - add FATTR_CTIME * - add ctime and ctimensec to fuse_setattr_in * - add FUSE_RENAME2 request + * - add FUSE_NO_OPEN_SUPPORT flag */ #ifndef _LINUX_FUSE_H @@ -229,6 +230,7 @@ struct fuse_file_lock { * FUSE_READDIRPLUS_AUTO: adaptive readdirplus * FUSE_ASYNC_DIO: asynchronous direct I/O submission * FUSE_WRITEBACK_CACHE: use writeback cache for buffered writes + * FUSE_NO_OPEN_SUPPORT: kernel supports zero-message opens */ #define FUSE_ASYNC_READ (1 << 0) #define FUSE_POSIX_LOCKS (1 << 1) @@ -247,6 +249,7 @@ struct fuse_file_lock { #define FUSE_READDIRPLUS_AUTO (1 << 14) #define FUSE_ASYNC_DIO (1 << 15) #define FUSE_WRITEBACK_CACHE (1 << 16) +#define FUSE_NO_OPEN_SUPPORT (1 << 17) /** * CUSE INIT request/reply flags diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c index 1911863..f25d56f 100755 --- a/lib/fuse_lowlevel.c +++ b/lib/fuse_lowlevel.c @@ -1923,6 +1923,8 @@ static void do_init(fuse_req_t req, fuse_ino_t nodeid, const void *inarg) f->conn.capable |= FUSE_CAP_ASYNC_DIO; if (arg->flags & FUSE_WRITEBACK_CACHE) f->conn.capable |= FUSE_CAP_WRITEBACK_CACHE; + if (arg->flags & FUSE_NO_OPEN_SUPPORT) + f->conn.capable |= FUSE_CAP_NO_OPEN_SUPPORT; } else { f->conn.async_read = 0; f->conn.max_readahead = 0; |