diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c index 09f07dadf4044..66cd479733987 100644 --- a/drivers/md/raid5.c +++ b/drivers/md/raid5.c @@ -5057,8 +5057,10 @@ static int run(mddev_t *mddev) list_for_each_entry(rdev, &mddev->disks, same_set) { if (rdev->raid_disk < 0) continue; - if (test_bit(In_sync, &rdev->flags)) + if (test_bit(In_sync, &rdev->flags)) { working_disks++; + continue; + } /* This disc is not fully in-sync. However if it * just stored parity (beyond the recovery_offset), * when we don't need to be concerned about the