74b1de
From 84d8a0ca5b521b9d87679ffebe420fe69869961d Mon Sep 17 00:00:00 2001
74b1de
From: Kinglong Mee <kinglongmee@gmail.com>
74b1de
Date: Mon, 8 Jul 2019 21:13:28 +0800
74b1de
Subject: [PATCH 270/276] cluster/ec: inherit healing from lock when it has
74b1de
 info
74b1de
74b1de
If lock has info, fop should inherit healing mask from it.
74b1de
Otherwise, fop cannot inherit right healing when changed_flags is zero.
74b1de
74b1de
Upstream-patch: https://review.gluster.org/c/glusterfs/+/23010
74b1de
Change-Id: Ife80c9169d2c555024347a20300b0583f7e8a87f
74b1de
fixes: bz#1732792
74b1de
Signed-off-by: Kinglong Mee <mijinlong@horiscale.com>
74b1de
Reviewed-on: https://code.engineering.redhat.com/gerrit/177974
74b1de
Tested-by: RHGS Build Bot <nigelb@redhat.com>
74b1de
Reviewed-by: Sunil Kumar Heggodu Gopala Acharya <sheggodu@redhat.com>
74b1de
---
74b1de
 xlators/cluster/ec/src/ec-common.c | 5 +++--
74b1de
 1 file changed, 3 insertions(+), 2 deletions(-)
74b1de
74b1de
diff --git a/xlators/cluster/ec/src/ec-common.c b/xlators/cluster/ec/src/ec-common.c
74b1de
index e2e582f..db1ff5b 100644
74b1de
--- a/xlators/cluster/ec/src/ec-common.c
74b1de
+++ b/xlators/cluster/ec/src/ec-common.c
74b1de
@@ -1412,11 +1412,12 @@ ec_get_size_version(ec_lock_link_t *link)
74b1de
     set_dirty = ec_set_dirty_flag(link, ctx, dirty);
74b1de
 
74b1de
     /* If ec metadata has already been retrieved, do not try again. */
74b1de
-    if (ctx->have_info && (!set_dirty)) {
74b1de
+    if (ctx->have_info) {
74b1de
         if (ec_is_data_fop(fop->id)) {
74b1de
             fop->healing |= lock->healing;
74b1de
         }
74b1de
-        goto unlock;
74b1de
+        if (!set_dirty)
74b1de
+            goto unlock;
74b1de
     }
74b1de
 
74b1de
     /* Determine if there's something we need to retrieve for the current
74b1de
-- 
74b1de
1.8.3.1
74b1de