aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/raid5.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/md/raid5.c')
-rw-r--r--drivers/md/raid5.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index 6234b2e84587..183588b11fc1 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -2922,7 +2922,7 @@ static int fetch_block(struct stripe_head *sh, struct stripe_head_state *s,
2922 (!test_bit(R5_Insync, &dev->flags) || test_bit(STRIPE_PREREAD_ACTIVE, &sh->state)) && 2922 (!test_bit(R5_Insync, &dev->flags) || test_bit(STRIPE_PREREAD_ACTIVE, &sh->state)) &&
2923 !test_bit(R5_OVERWRITE, &fdev[0]->flags)) || 2923 !test_bit(R5_OVERWRITE, &fdev[0]->flags)) ||
2924 (sh->raid_conf->level == 6 && s->failed && s->to_write && 2924 (sh->raid_conf->level == 6 && s->failed && s->to_write &&
2925 s->to_write < sh->raid_conf->raid_disks - 2 && 2925 s->to_write - s->non_overwrite < sh->raid_conf->raid_disks - 2 &&
2926 (!test_bit(R5_Insync, &dev->flags) || test_bit(STRIPE_PREREAD_ACTIVE, &sh->state))))) { 2926 (!test_bit(R5_Insync, &dev->flags) || test_bit(STRIPE_PREREAD_ACTIVE, &sh->state))))) {
2927 /* we would like to get this block, possibly by computing it, 2927 /* we would like to get this block, possibly by computing it,
2928 * otherwise read it if the backing disk is insync 2928 * otherwise read it if the backing disk is insync
@@ -3817,6 +3817,8 @@ static void handle_stripe(struct stripe_head *sh)
3817 set_bit(R5_Wantwrite, &dev->flags); 3817 set_bit(R5_Wantwrite, &dev->flags);
3818 if (prexor) 3818 if (prexor)
3819 continue; 3819 continue;
3820 if (s.failed > 1)
3821 continue;
3820 if (!test_bit(R5_Insync, &dev->flags) || 3822 if (!test_bit(R5_Insync, &dev->flags) ||
3821 ((i == sh->pd_idx || i == sh->qd_idx) && 3823 ((i == sh->pd_idx || i == sh->qd_idx) &&
3822 s.failed == 0)) 3824 s.failed == 0))