summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src/afr.h
diff options
context:
space:
mode:
authorVikas Gorur <vikas@gluster.com>2009-07-14 08:05:14 +0000
committerAnand V. Avati <avati@dev.gluster.com>2009-07-16 00:37:37 -0700
commite07a362a54c6f1bff5b87ce30a5302f0cd01c086 (patch)
tree8248e6bf5bb4be69e69fbd766afb6a73f873586e /xlators/cluster/afr/src/afr.h
parent3ce764351c0cdf01637eb0f19ec9846e91ca3f35 (diff)
Return stat info from read-child in all the inode-write ops
Also modifies the inode-write ops to wait for the call to read-child to return (whether success or failure) before unwinding. Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 125 (stat information not returned from the same subvolume always) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=125
Diffstat (limited to 'xlators/cluster/afr/src/afr.h')
-rw-r--r--xlators/cluster/afr/src/afr.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/xlators/cluster/afr/src/afr.h b/xlators/cluster/afr/src/afr.h
index a4facf2074f..1e9ced4ed97 100644
--- a/xlators/cluster/afr/src/afr.h
+++ b/xlators/cluster/afr/src/afr.h
@@ -145,6 +145,7 @@ typedef struct _afr_local {
unsigned int govinda_gOvinda;
unsigned int read_child_index;
+ unsigned char read_child_returned;
pid_t saved_pid;
@@ -182,6 +183,7 @@ typedef struct _afr_local {
struct {
inode_t *inode;
struct stat buf;
+ struct stat read_child_buf;
ino_t ino;
dict_t *xattr;
} lookup;
@@ -268,12 +270,14 @@ typedef struct _afr_local {
ino_t ino;
mode_t mode;
struct stat buf;
+ struct stat read_child_buf;
} chmod;
struct {
ino_t ino;
mode_t mode;
struct stat buf;
+ struct stat read_child_buf;
} fchmod;
struct {
@@ -281,6 +285,7 @@ typedef struct _afr_local {
uid_t uid;
gid_t gid;
struct stat buf;
+ struct stat read_child_buf;
} chown;
struct {
@@ -288,11 +293,13 @@ typedef struct _afr_local {
uid_t uid;
gid_t gid;
struct stat buf;
+ struct stat read_child_buf;
} fchown;
struct {
ino_t ino;
struct stat buf;
+ struct stat read_child_buf;
int32_t op_ret;
@@ -306,18 +313,21 @@ typedef struct _afr_local {
ino_t ino;
off_t offset;
struct stat buf;
+ struct stat read_child_buf;
} truncate;
struct {
ino_t ino;
off_t offset;
struct stat buf;
+ struct stat read_child_buf;
} ftruncate;
struct {
ino_t ino;
struct timespec tv[2];
struct stat buf;
+ struct stat read_child_buf;
} utimens;
struct {