summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xrun-tests.sh1
-rw-r--r--xlators/cluster/ec/src/ec-common.c12
2 files changed, 7 insertions, 6 deletions
diff --git a/run-tests.sh b/run-tests.sh
index f94f86c..0d764a4 100755
--- a/run-tests.sh
+++ b/run-tests.sh
@@ -205,7 +205,6 @@ function is_bad_test ()
./tests/geo-rep/georep-basic-dr-rsync.t \
./tests/geo-rep/georep-basic-dr-tarssh.t \
./tests/bugs/replicate/bug-1221481-allow-fops-on-dir-split-brain.t \
- ./tests/basic/ec/ec-readdir.t \
; do
[ x"$name" = x"$bt" ] && return 0 # bash: zero means true/success
done
diff --git a/xlators/cluster/ec/src/ec-common.c b/xlators/cluster/ec/src/ec-common.c
index a7d6da4..da67dbc 100644
--- a/xlators/cluster/ec/src/ec-common.c
+++ b/xlators/cluster/ec/src/ec-common.c
@@ -154,11 +154,12 @@ void ec_lock_update_good(ec_lock_t *lock, ec_fop_data_t *fop)
return;
}
- /* When updating the good mask of the lock, we only take into
- * consideration those bits corresponding to the bricks where
- * the fop has been executed. */
- lock->good_mask &= ~fop->mask | fop->remaining;
- lock->good_mask |= fop->good;
+ /* When updating the good mask of the lock, we only take into consideration
+ * those bits corresponding to the bricks where the fop has been executed.
+ * Bad bricks are removed from good_mask, but once marked as bad it's never
+ * set to good until the lock is released and reacquired */
+
+ lock->good_mask &= fop->good | fop->remaining;
}
void __ec_fop_set_error(ec_fop_data_t * fop, int32_t error)
@@ -981,6 +982,7 @@ unlock:
/* We don't allow the main fop to be executed on bricks that have not
* succeeded the initial xattrop. */
parent->mask &= fop->good;
+ ec_lock_update_good (lock, fop);
/*As of now only data healing marks bricks as healing*/
lock->healing |= fop->healing;