From f5d5e8012a3762d0ffb95a0ca624a3fce3c262cd Mon Sep 17 00:00:00 2001 From: Raghavendra G Date: Thu, 24 Nov 2011 13:50:23 +0530 Subject: mount/fuse: Inherit direct-io-mode values from fds already opened, for a new fd being opened. When an fd is being opened, it inherits direct-io-mode characterstics (either enabled or disabled) from the fds already opened on inode. If none are opened and user has not specified the mode through cmdline options, default mode is used. Change-Id: I0c9e959100e9130e46bbd16d63eca278260635b4 BUG: 801 Reviewed-on: http://review.gluster.com/55 Tested-by: Gluster Build System Reviewed-by: Csaba Henk Reviewed-by: Anand Avati --- xlators/mount/fuse/src/fuse-bridge.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'xlators/mount/fuse/src/fuse-bridge.h') diff --git a/xlators/mount/fuse/src/fuse-bridge.h b/xlators/mount/fuse/src/fuse-bridge.h index 2b8323a8c..b7ca9b08e 100644 --- a/xlators/mount/fuse/src/fuse-bridge.h +++ b/xlators/mount/fuse/src/fuse-bridge.h @@ -277,6 +277,11 @@ typedef struct { uuid_t gfid; } fuse_state_t; +typedef struct fuse_fd_ctx { + uint32_t open_flags; + fd_t *fd; +} fuse_fd_ctx_t; + typedef void (*fuse_resume_fn_t) (fuse_state_t *state); GF_MUST_CHECK int32_t @@ -296,4 +301,6 @@ int fuse_gfid_set (fuse_state_t *state); int fuse_flip_xattr_ns (struct fuse_private *priv, char *okey, char **nkey); int fuse_flip_user_to_trusted (char *okey, char **nkey); int fuse_xattr_alloc_default (char *okey, char **nkey); +fuse_fd_ctx_t * __fuse_fd_ctx_check_n_create (fd_t *fd, xlator_t *this); +fuse_fd_ctx_t * fuse_fd_ctx_check_n_create (fd_t *fd, xlator_t *this); #endif /* _GF_FUSE_BRIDGE_H_ */ -- cgit