From c5d9ac3477d295b5e97166ac655a52463a0d1fb8 Mon Sep 17 00:00:00 2001 From: Pranith Kumar K Date: Mon, 23 Apr 2012 19:58:41 +0530 Subject: cluster/afr: Perform Flush with lk-owner given by parent xlator. Lk-owner of posix-lk and flush should be same, flush can't clear posix-lks without that lk-owner. Change-Id: If775abb5741a0beb00c419b54d023fbd429e3cb7 BUG: 810502 Signed-off-by: Pranith Kumar K Reviewed-on: http://review.gluster.com/3221 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- xlators/cluster/afr/src/afr-transaction.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'xlators/cluster/afr/src/afr-transaction.c') diff --git a/xlators/cluster/afr/src/afr-transaction.c b/xlators/cluster/afr/src/afr-transaction.c index c46ec6cf6..dedc0ba62 100644 --- a/xlators/cluster/afr/src/afr-transaction.c +++ b/xlators/cluster/afr/src/afr-transaction.c @@ -1214,6 +1214,11 @@ afr_internal_lock_finish (call_frame_t *frame, xlator_t *this) priv = this->private; local = frame->local; + /* Perform fops with the lk-owner from top xlator. + * Eg: lk-owner of posix-lk and flush should be same, + * flush cant clear the posix-lks without that lk-owner. + */ + frame->root->lk_owner = local->transaction.main_frame->root->lk_owner; if (__fop_changelog_needed (frame, this)) { afr_changelog_pre_op (frame, this); } else { -- cgit