diff options
Diffstat (limited to 'drivers/md')
-rw-r--r-- | drivers/md/dm-raid.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/md/dm-raid.c b/drivers/md/dm-raid.c index 59d15ec0ba81..49f0bd510fb9 100644 --- a/drivers/md/dm-raid.c +++ b/drivers/md/dm-raid.c | |||
@@ -1587,6 +1587,21 @@ static void attempt_restore_of_faulty_devices(struct raid_set *rs) | |||
1587 | DMINFO("Faulty %s device #%d has readable super block." | 1587 | DMINFO("Faulty %s device #%d has readable super block." |
1588 | " Attempting to revive it.", | 1588 | " Attempting to revive it.", |
1589 | rs->raid_type->name, i); | 1589 | rs->raid_type->name, i); |
1590 | |||
1591 | /* | ||
1592 | * Faulty bit may be set, but sometimes the array can | ||
1593 | * be suspended before the personalities can respond | ||
1594 | * by removing the device from the array (i.e. calling | ||
1595 | * 'hot_remove_disk'). If they haven't yet removed | ||
1596 | * the failed device, its 'raid_disk' number will be | ||
1597 | * '>= 0' - meaning we must call this function | ||
1598 | * ourselves. | ||
1599 | */ | ||
1600 | if ((r->raid_disk >= 0) && | ||
1601 | (r->mddev->pers->hot_remove_disk(r->mddev, r) != 0)) | ||
1602 | /* Failed to revive this device, try next */ | ||
1603 | continue; | ||
1604 | |||
1590 | r->raid_disk = i; | 1605 | r->raid_disk = i; |
1591 | r->saved_raid_disk = i; | 1606 | r->saved_raid_disk = i; |
1592 | flags = r->flags; | 1607 | flags = r->flags; |