From 7142125937e1482ad3ae4366594c6586153dfc86 Mon Sep 17 00:00:00 2001 From: Miklos Szeredi Date: Sun, 25 Jun 2006 05:48:52 -0700 Subject: [PATCH] fuse: add POSIX file locking support This patch adds POSIX file locking support to the fuse interface. This implementation doesn't keep any locking state in kernel. Unlocking on close() is handled by the FLUSH message, which now contains the lock owner id. Mandatory locking is not supported. The filesystem may enfoce mandatory locking in userspace if needed. Signed-off-by: Miklos Szeredi Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- fs/fuse/fuse_i.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'fs/fuse/fuse_i.h') diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h index ac12b01f444..eb3166625ca 100644 --- a/fs/fuse/fuse_i.h +++ b/fs/fuse/fuse_i.h @@ -190,6 +190,7 @@ struct fuse_req { struct fuse_init_in init_in; struct fuse_init_out init_out; struct fuse_read_in read_in; + struct fuse_lk_in lk_in; } misc; /** page vector */ @@ -307,6 +308,9 @@ struct fuse_conn { /** Is removexattr not implemented by fs? */ unsigned no_removexattr : 1; + /** Are file locking primitives not implemented by fs? */ + unsigned no_lock : 1; + /** Is access not implemented by fs? */ unsigned no_access : 1; -- cgit v1.2.3