aboutsummaryrefslogtreecommitdiffstats
path: root/include/fuse_kernel.h
diff options
context:
space:
mode:
authorMiklos Szeredi <miklos@szeredi.hu>2008-12-08 19:26:53 +0000
committerMiklos Szeredi <miklos@szeredi.hu>2008-12-08 19:26:53 +0000
commit5f722fa8f6561c964fd0bd651b4602ac0f7bc3b4 (patch)
tree47a21b51e3d8319b1c929c461a4934d62134164d /include/fuse_kernel.h
parentecfa5263ab5b19a58d53a7116fb079f3b956b918 (diff)
downloadlibfuse-5f722fa8f6561c964fd0bd651b4602ac0f7bc3b4.tar.gz
* Implement poll support. Patch by Tejun Heo
Diffstat (limited to 'include/fuse_kernel.h')
-rw-r--r--include/fuse_kernel.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/include/fuse_kernel.h b/include/fuse_kernel.h
index eb28a35..df558e3 100644
--- a/include/fuse_kernel.h
+++ b/include/fuse_kernel.h
@@ -49,6 +49,8 @@
*
* 7.11
* - add IOCTL message
+ * - add unsolicited notification support
+ * - add POLL message and NOTIFY_POLL notification
*/
#ifndef _LINUX_FUSE_H
@@ -191,6 +193,13 @@ struct fuse_file_lock {
#define FUSE_IOCTL_MAX_IOV 256
+/**
+ * Poll flags
+ *
+ * FUSE_POLL_SCHEDULE_NOTIFY: request poll notify
+ */
+#define FUSE_POLL_SCHEDULE_NOTIFY (1 << 0)
+
enum fuse_opcode {
FUSE_LOOKUP = 1,
FUSE_FORGET = 2, /* no reply */
@@ -229,6 +238,12 @@ enum fuse_opcode {
FUSE_BMAP = 37,
FUSE_DESTROY = 38,
FUSE_IOCTL = 39,
+ FUSE_POLL = 40,
+};
+
+enum fuse_notify_code {
+ FUSE_NOTIFY_POLL = 1,
+ FUSE_NOTIFY_CODE_MAX,
};
/* The read buffer is required to be at least 8k, but may be much larger */
@@ -445,6 +460,22 @@ struct fuse_ioctl_out {
__u32 out_iovs;
};
+struct fuse_poll_in {
+ __u64 fh;
+ __u64 kh;
+ __u32 flags;
+ __u32 padding;
+};
+
+struct fuse_poll_out {
+ __u32 revents;
+ __u32 padding;
+};
+
+struct fuse_notify_poll_wakeup_out {
+ __u64 kh;
+};
+
struct fuse_in_header {
__u32 len;
__u32 opcode;