Patch "dm btree remove: fix bug in redistribute3" has been added to the 3.10-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
dm btree remove: fix bug in redistribute3
to the 3.10-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
dm-btree-remove-fix-bug-in-redistribute3.patch
and it can be found in the queue-3.10 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
4c7e309340ff85072e96f529582d159002c36734Mon Sep 17 00:00:00 2001
From: Dennis Yang <[email protected]>
Date: Fri, 26 Jun 2015 15:25:48 +0100
Subject: dm btree remove: fix bug in redistribute3
From: Dennis Yang <[email protected]>
commit 4c7e309340ff85072e96f529582d159002c36734 upstream.
redistribute3() shares entries out across 3 nodes. Some entries were being moved the wrong way, breaking the ordering. This manifested as a BUG() in dm-btree-remove.c:shift() when entries were removed from the btree.
For additional context see:
https://www.redhat.com/archives/dm-devel/2015-May/msg00113.html
--- drivers/md/persistent-data/dm-btree-remove.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/md/persistent-data/dm-btree-remove.c +3 -3
@@ -309,8 +309,8 @@ static void redistribute3(struct dm_btreif (s <0 && nr_center < -s) {/* not enough in central node */ -shift (left, center, nr_center); - s = nr_center - target; +shift (left, center, -nr_center); + s += nr_center;shift (left, right, s); nr_right += s; }else
@@ -323,7 +323,7 @@ static void redistribute3(struct dm_btreif (s >0 && nr_center < s) {/* not enough in central node */ shift (center, right, nr_center); - s = target - nr_center; + s -= nr_center;shift (left, right, s); nr_left -= s; }else
Patches currently in stable-queue which might be from [email protected] are
queue-3.10/dm-btree-remove-fix-bug-in-redistribute3.patch