From 360868e9b010f770bd727570e0f0404069c3375a Mon Sep 17 00:00:00 2001 From: Pranith Kumar K Date: Tue, 29 Jan 2013 17:58:09 +0530 Subject: cluster/afr: wakeup delayed post op on fsync Change-Id: I5d84ef72615f9d71b4af210976e2449de6e02326 BUG: 888174 Signed-off-by: Pranith Kumar K Reviewed-on: http://review.gluster.org/4446 Tested-by: Gluster Build System Reviewed-by: Anand Avati --- xlators/cluster/afr/src/afr-common.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'xlators/cluster/afr/src/afr-common.c') diff --git a/xlators/cluster/afr/src/afr-common.c b/xlators/cluster/afr/src/afr-common.c index 5c4a649b95e..424a6997160 100644 --- a/xlators/cluster/afr/src/afr-common.c +++ b/xlators/cluster/afr/src/afr-common.c @@ -2557,11 +2557,7 @@ afr_flush (call_frame_t *frame, xlator_t *this, fd_t *fd, dict_t *xdata) local->fd = fd_ref(fd); call_count = local->call_count; - /* - * Ideally we should synchronize flush against completion of writing - * the delayed changelog, but for now we just push it out first... - */ - afr_delayed_changelog_wake_up(this, fd); + afr_delayed_changelog_wake_up (this, fd); for (i = 0; i < priv->child_count; i++) { if (local->child_up[i]) { @@ -2739,6 +2735,8 @@ afr_fsync (call_frame_t *frame, xlator_t *this, fd_t *fd, local->fd = fd_ref (fd); + afr_delayed_changelog_wake_up (this, fd); + for (i = 0; i < priv->child_count; i++) { if (local->child_up[i]) { STACK_WIND_COOKIE (frame, afr_fsync_cbk, -- cgit