diff options
-rw-r--r-- | drivers/md/raid1.c | 8 | ||||
-rw-r--r-- | drivers/md/raid10.c | 11 |
2 files changed, 9 insertions, 10 deletions
diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c index 56e24c072b62..d7690f86fdb9 100644 --- a/drivers/md/raid1.c +++ b/drivers/md/raid1.c | |||
@@ -1501,12 +1501,12 @@ static void error(struct mddev *mddev, struct md_rdev *rdev) | |||
1501 | mddev->degraded++; | 1501 | mddev->degraded++; |
1502 | set_bit(Faulty, &rdev->flags); | 1502 | set_bit(Faulty, &rdev->flags); |
1503 | spin_unlock_irqrestore(&conf->device_lock, flags); | 1503 | spin_unlock_irqrestore(&conf->device_lock, flags); |
1504 | /* | ||
1505 | * if recovery is running, make sure it aborts. | ||
1506 | */ | ||
1507 | set_bit(MD_RECOVERY_INTR, &mddev->recovery); | ||
1508 | } else | 1504 | } else |
1509 | set_bit(Faulty, &rdev->flags); | 1505 | set_bit(Faulty, &rdev->flags); |
1506 | /* | ||
1507 | * if recovery is running, make sure it aborts. | ||
1508 | */ | ||
1509 | set_bit(MD_RECOVERY_INTR, &mddev->recovery); | ||
1510 | set_bit(MD_CHANGE_DEVS, &mddev->flags); | 1510 | set_bit(MD_CHANGE_DEVS, &mddev->flags); |
1511 | printk(KERN_ALERT | 1511 | printk(KERN_ALERT |
1512 | "md/raid1:%s: Disk failure on %s, disabling device.\n" | 1512 | "md/raid1:%s: Disk failure on %s, disabling device.\n" |
diff --git a/drivers/md/raid10.c b/drivers/md/raid10.c index cb882aae9e20..b08c18871323 100644 --- a/drivers/md/raid10.c +++ b/drivers/md/raid10.c | |||
@@ -1684,13 +1684,12 @@ static void error(struct mddev *mddev, struct md_rdev *rdev) | |||
1684 | spin_unlock_irqrestore(&conf->device_lock, flags); | 1684 | spin_unlock_irqrestore(&conf->device_lock, flags); |
1685 | return; | 1685 | return; |
1686 | } | 1686 | } |
1687 | if (test_and_clear_bit(In_sync, &rdev->flags)) { | 1687 | if (test_and_clear_bit(In_sync, &rdev->flags)) |
1688 | mddev->degraded++; | 1688 | mddev->degraded++; |
1689 | /* | 1689 | /* |
1690 | * if recovery is running, make sure it aborts. | 1690 | * If recovery is running, make sure it aborts. |
1691 | */ | 1691 | */ |
1692 | set_bit(MD_RECOVERY_INTR, &mddev->recovery); | 1692 | set_bit(MD_RECOVERY_INTR, &mddev->recovery); |
1693 | } | ||
1694 | set_bit(Blocked, &rdev->flags); | 1693 | set_bit(Blocked, &rdev->flags); |
1695 | set_bit(Faulty, &rdev->flags); | 1694 | set_bit(Faulty, &rdev->flags); |
1696 | set_bit(MD_CHANGE_DEVS, &mddev->flags); | 1695 | set_bit(MD_CHANGE_DEVS, &mddev->flags); |