summaryrefslogtreecommitdiff
path: root/fs/fuse/fuse_i.h
diff options
context:
space:
mode:
authorMiklos Szeredi <miklos@szeredi.hu>2005-09-09 13:10:35 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2005-09-09 14:03:46 -0700
commit413ef8cb302511d8e995e2b0e5517ee1a65b9c77 (patch)
tree59acb15a73fa0dc4393a086fb83f016105d84b2a /fs/fuse/fuse_i.h
parent5a53368277efa2d80dd2206dddc1f4b19ef0c32a (diff)
downloadlinux-3.10-413ef8cb302511d8e995e2b0e5517ee1a65b9c77.tar.gz
linux-3.10-413ef8cb302511d8e995e2b0e5517ee1a65b9c77.tar.bz2
linux-3.10-413ef8cb302511d8e995e2b0e5517ee1a65b9c77.zip
[PATCH] FUSE - direct I/O
This patch adds support for the "direct_io" mount option of FUSE. When this mount option is specified, the page cache is bypassed for read and write operations. This is useful for example, if the filesystem doesn't know the size of files before reading them, or when any kind of caching is harmful. Signed-off-by: Miklos Szeredi <miklos@szeredi.hu> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/fuse/fuse_i.h')
-rw-r--r--fs/fuse/fuse_i.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h
index 3ec2aff3fdb..0af1ac64692 100644
--- a/fs/fuse/fuse_i.h
+++ b/fs/fuse/fuse_i.h
@@ -34,6 +34,9 @@
be flushed on open */
#define FUSE_KERNEL_CACHE (1 << 2)
+/** Bypass the page cache for read and write operations */
+#define FUSE_DIRECT_IO (1 << 3)
+
/** FUSE inode */
struct fuse_inode {
/** Inode data */
@@ -207,6 +210,9 @@ struct fuse_conn {
/** Maximum read size */
unsigned max_read;
+ /** Maximum write size */
+ unsigned max_write;
+
/** Readers of the connection are waiting on this */
wait_queue_head_t waitq;