diff options
author | NeilBrown <neilb@suse.de> | 2006-10-23 17:07:48 +1000 |
---|---|---|
committer | Chris Wright <chrisw@sous-sol.org> | 2006-11-03 17:33:47 -0800 |
commit | 563f2416b31884d196f194bcca580f8226b1dc4a (patch) | |
tree | fe1c527ba25bc2b91170e3d87e93e71f2416cfb5 | |
parent | 1e4007bf4ef92fc6d2afa418c1b49921a7c7d0b3 (diff) |
[PATCH] md: Fix bug where spares don't always get rebuilt properly when they become live.
If save_raid_disk is >= 0, then the device could be a device that is
already in sync that is being re-added. So we need to default this
value to -1.
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
-rw-r--r-- | drivers/md/md.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c index c9d2919347df..1869e819afb8 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -1994,6 +1994,7 @@ static mdk_rdev_t *md_import_device(dev_t newdev, int super_format, int super_mi kobject_init(&rdev->kobj); rdev->desc_nr = -1; + rdev->saved_raid_disk = -1; rdev->flags = 0; rdev->data_offset = 0; rdev->sb_events = 0; |