aboutsummaryrefslogtreecommitdiffstats
path: root/fs/fuse/fuse_i.h
diff options
context:
space:
mode:
authorMiklos Szeredi <miklos@szeredi.hu>2005-09-09 16:10:30 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-09-09 17:03:45 -0400
commitb6aeadeda22a9aa322fdfcd3f4c69ccf0da5cbdd (patch)
tree794afec0eeb13722550a97783ec0cfb95e5e83cb /fs/fuse/fuse_i.h
parent9e6268db496a2592e89457537ea54a496feabb77 (diff)
[PATCH] FUSE - file operations
This patch adds the file operations of FUSE. The following operations are added: o open o flush o release o fsync o readpage o commit_write 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.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h
index 87d25b8f2dc1..b4aa8f7bc2c1 100644
--- a/fs/fuse/fuse_i.h
+++ b/fs/fuse/fuse_i.h
@@ -40,6 +40,15 @@ struct fuse_inode {
40 unsigned long i_time; 40 unsigned long i_time;
41}; 41};
42 42
43/** FUSE specific file data */
44struct fuse_file {
45 /** Request reserved for flush and release */
46 struct fuse_req *release_req;
47
48 /** File handle used by userspace */
49 u64 fh;
50};
51
43/** One input argument of a request */ 52/** One input argument of a request */
44struct fuse_in_arg { 53struct fuse_in_arg {
45 unsigned size; 54 unsigned size;
@@ -136,6 +145,7 @@ struct fuse_req {
136 /** Data for asynchronous requests */ 145 /** Data for asynchronous requests */
137 union { 146 union {
138 struct fuse_forget_in forget_in; 147 struct fuse_forget_in forget_in;
148 struct fuse_release_in release_in;
139 struct fuse_init_in_out init_in_out; 149 struct fuse_init_in_out init_in_out;
140 } misc; 150 } misc;
141 151
@@ -200,6 +210,12 @@ struct fuse_conn {
200 /** Connection failed (version mismatch) */ 210 /** Connection failed (version mismatch) */
201 unsigned conn_error : 1; 211 unsigned conn_error : 1;
202 212
213 /** Is fsync not implemented by fs? */
214 unsigned no_fsync : 1;
215
216 /** Is flush not implemented by fs? */
217 unsigned no_flush : 1;
218
203 /** Backing dev info */ 219 /** Backing dev info */
204 struct backing_dev_info bdi; 220 struct backing_dev_info bdi;
205}; 221};
@@ -264,6 +280,11 @@ void fuse_send_forget(struct fuse_conn *fc, struct fuse_req *req,
264 unsigned long nodeid, u64 nlookup); 280 unsigned long nodeid, u64 nlookup);
265 281
266/** 282/**
283 * Initialise file operations on a regular file
284 */
285void fuse_init_file_inode(struct inode *inode);
286
287/**
267 * Initialise inode operations on regular files and special files 288 * Initialise inode operations on regular files and special files
268 */ 289 */
269void fuse_init_common(struct inode *inode); 290void fuse_init_common(struct inode *inode);