aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2013-02-07 02:52:41 +0000
committerMiklos Szeredi <mszeredi@suse.cz>2013-02-07 14:59:28 +0100
commitc66e7f4e71a10e0a06d903d11acad8cc6b99c16a (patch)
tree811911c9279e6d55152d0c2e03fd91970e2219a6 /include
parent1bea285a3a586c97597b1f690f14051ff63f3f0b (diff)
downloadlibfuse-c66e7f4e71a10e0a06d903d11acad8cc6b99c16a.tar.gz
libfuse: allow disabling adaptive readdirplus
This switches the -o no_readdirplus option to a tristate string: -o readdirplus=(yes|no|auto) Telling the kernel to always use readdirplus is beneficial to filesystems (e.g. GlusterFS) where the cost to perform readdir and readdirplus are identical. The default remains "auto" (if supported).
Diffstat (limited to 'include')
-rw-r--r--include/fuse_common.h1
-rw-r--r--include/fuse_kernel.h3
2 files changed, 4 insertions, 0 deletions
diff --git a/include/fuse_common.h b/include/fuse_common.h
index cb2d8cf..78d3ce4 100644
--- a/include/fuse_common.h
+++ b/include/fuse_common.h
@@ -118,6 +118,7 @@ struct fuse_file_info {
#define FUSE_CAP_IOCTL_DIR (1 << 11)
#define FUSE_CAP_AUTO_INVAL_DATA (1 << 12)
#define FUSE_CAP_READDIRPLUS (1 << 13)
+#define FUSE_CAP_READDIRPLUS_AUTO (1 << 14)
/**
* Ioctl flags
diff --git a/include/fuse_kernel.h b/include/fuse_kernel.h
index baee03e..4c43b44 100644
--- a/include/fuse_kernel.h
+++ b/include/fuse_kernel.h
@@ -218,6 +218,8 @@ struct fuse_file_lock {
* FUSE_FLOCK_LOCKS: remote locking for BSD style file locks
* FUSE_HAS_IOCTL_DIR: kernel supports ioctl on directories
* FUSE_AUTO_INVAL_DATA: automatically invalidate cached pages
+ * FUSE_DO_READDIRPLUS: do READDIRPLUS (READDIR+LOOKUP in one)
+ * FUSE_READDIRPLUS_AUTO: adaptive readdirplus
*/
#define FUSE_ASYNC_READ (1 << 0)
#define FUSE_POSIX_LOCKS (1 << 1)
@@ -233,6 +235,7 @@ struct fuse_file_lock {
#define FUSE_HAS_IOCTL_DIR (1 << 11)
#define FUSE_AUTO_INVAL_DATA (1 << 12)
#define FUSE_DO_READDIRPLUS (1 << 13)
+#define FUSE_READDIRPLUS_AUTO (1 << 14)
/**
* CUSE INIT request/reply flags