summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src/afr.h
diff options
context:
space:
mode:
authorVikas Gorur <vikas@gluster.com>2009-04-07 06:55:43 -0700
committerAnand V. Avati <avati@amp.gluster.com>2009-04-07 23:19:08 +0530
commit5634986f594fe75d0cd2e69cadf002a2c701f366 (patch)
treeded4a1c4e4eba480a5abd30f133874e5a0f0c410 /xlators/cluster/afr/src/afr.h
parentd46684117a02359886e096d1bcc9f590b54144a6 (diff)
Fix in changelog logic.
If a writev fails, remember it by marking it in the fd context. Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
Diffstat (limited to 'xlators/cluster/afr/src/afr.h')
-rw-r--r--xlators/cluster/afr/src/afr.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/xlators/cluster/afr/src/afr.h b/xlators/cluster/afr/src/afr.h
index 76ccec2ae0b..10e50c967ca 100644
--- a/xlators/cluster/afr/src/afr.h
+++ b/xlators/cluster/afr/src/afr.h
@@ -394,6 +394,12 @@ typedef struct _afr_local {
} afr_local_t;
+typedef struct {
+ unsigned char pre_op_done;
+ unsigned char *child_failed;
+} afr_fd_ctx_t;
+
+
/* try alloc and if it fails, goto label */
#define ALLOC_OR_GOTO(var, type, label) do { \
var = CALLOC (sizeof (type), 1); \
@@ -416,6 +422,9 @@ typedef struct _afr_local {
/* have we tried all children? */
#define all_tried(i, count) ((i) == (count) - 1)
+int
+afr_fd_ctx_set (xlator_t *this, fd_t *fd);
+
uint64_t
afr_read_child (xlator_t *this, inode_t *inode);