diff options
author | Andre Noll <maan@systemlinux.org> | 2009-03-31 00:00:56 -0400 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2009-03-31 00:00:56 -0400 |
commit | 18b0033491f584a2d79697da714b1ef9d6b27d22 (patch) | |
tree | c06549a4d8fb65418671d6f55a9d647975b9abbc | |
parent | b522adcde9c4d3fb7b579cfa9160d8bde7744be8 (diff) |
md: raid5 run(): Fix max_degraded for raid level 4.
raid4 allows only one failed disk.
Signed-off-by: Andre Noll <maan@systemlinux.org>
Signed-off-by: NeilBrown <neilb@suse.de>
-rw-r--r-- | drivers/md/raid5.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c index 1aebd3ef80b7..e1ee181b79bb 100644 --- a/drivers/md/raid5.c +++ b/drivers/md/raid5.c | |||
@@ -4331,7 +4331,7 @@ static int run(mddev_t *mddev) | |||
4331 | */ | 4331 | */ |
4332 | sector_t here_new, here_old; | 4332 | sector_t here_new, here_old; |
4333 | int old_disks; | 4333 | int old_disks; |
4334 | int max_degraded = (mddev->level == 5 ? 1 : 2); | 4334 | int max_degraded = (mddev->level == 6 ? 2 : 1); |
4335 | 4335 | ||
4336 | if (mddev->new_level != mddev->level || | 4336 | if (mddev->new_level != mddev->level || |
4337 | mddev->new_layout != mddev->layout || | 4337 | mddev->new_layout != mddev->layout || |