aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/bitmap.c
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2009-03-30 23:27:02 -0400
committerNeilBrown <neilb@suse.de>2009-03-30 23:27:02 -0400
commit355a43e641b948a7b755cb4c2466ec548d5b495f (patch)
treebed8f87adde74f054c6b822ffdbae74395e76710 /drivers/md/bitmap.c
parentd0a4bb492772ce5c4bdfba3744a99ed6f6fb238f (diff)
md: write bitmap information to devices that are undergoing recovery.
When we add some spares to an array and start recovery, and we have a bitmap which is stored 'internally' on all devices, we call bitmap_write_all to make sure the bitmap is correct on the new device(s). However that doesn't work as write_sb_page only writes to 'In_sync' devices, and devices undergoing recovery are not 'In_sync' until recovery finishes. So extend write_sb_page (actually next_active_rdev) to include devices that are under recovery. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/bitmap.c')
-rw-r--r--drivers/md/bitmap.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/md/bitmap.c b/drivers/md/bitmap.c
index 2ef497d1848c..27f978dfe6a3 100644
--- a/drivers/md/bitmap.c
+++ b/drivers/md/bitmap.c
@@ -266,7 +266,6 @@ static mdk_rdev_t *next_active_rdev(mdk_rdev_t *rdev, mddev_t *mddev)
266 list_for_each_continue_rcu(pos, &mddev->disks) { 266 list_for_each_continue_rcu(pos, &mddev->disks) {
267 rdev = list_entry(pos, mdk_rdev_t, same_set); 267 rdev = list_entry(pos, mdk_rdev_t, same_set);
268 if (rdev->raid_disk >= 0 && 268 if (rdev->raid_disk >= 0 &&
269 test_bit(In_sync, &rdev->flags) &&
270 !test_bit(Faulty, &rdev->flags)) { 269 !test_bit(Faulty, &rdev->flags)) {
271 /* this is a usable devices */ 270 /* this is a usable devices */
272 atomic_inc(&rdev->nr_pending); 271 atomic_inc(&rdev->nr_pending);