diff options
Diffstat (limited to 'drivers/md')
-rw-r--r-- | drivers/md/raid5.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c index b2c83859f75b..360f2b98f62b 100644 --- a/drivers/md/raid5.c +++ b/drivers/md/raid5.c | |||
@@ -1796,6 +1796,9 @@ static void raid5_end_write_request(struct bio *bi, int error) | |||
1796 | if (!uptodate) { | 1796 | if (!uptodate) { |
1797 | set_bit(WriteErrorSeen, &rdev->flags); | 1797 | set_bit(WriteErrorSeen, &rdev->flags); |
1798 | set_bit(R5_WriteError, &sh->dev[i].flags); | 1798 | set_bit(R5_WriteError, &sh->dev[i].flags); |
1799 | if (!test_and_set_bit(WantReplacement, &rdev->flags)) | ||
1800 | set_bit(MD_RECOVERY_NEEDED, | ||
1801 | &rdev->mddev->recovery); | ||
1799 | } else if (is_badblock(rdev, sh->sector, | 1802 | } else if (is_badblock(rdev, sh->sector, |
1800 | STRIPE_SECTORS, | 1803 | STRIPE_SECTORS, |
1801 | &first_bad, &bad_sectors)) | 1804 | &first_bad, &bad_sectors)) |