diff options
author | Nikanth Karthikesan <knikanth@novell.com> | 2008-06-28 02:31:19 +0400 |
---|---|---|
committer | Neil Brown <neilb@notabene.brown> | 2008-06-28 02:31:19 +0400 |
commit | 13864515f7bf6cabd60e63c62e09d311386ae1f1 (patch) | |
tree | 3f46035321aedab46c787cac01b17e6b24934423 /drivers/md/linear.c | |
parent | 9bbbca3a0ee09293108b67835c6bdf6196d7bcb3 (diff) | |
download | linux-13864515f7bf6cabd60e63c62e09d311386ae1f1.tar.xz |
linear: correct disk numbering error check
From: "Nikanth Karthikesan" <knikanth@novell.com>
Correct disk numbering problem check.
Signed-off-by: Nikanth Karthikesan <knikanth@suse.de>
Signed-off-by: Neil Brown <neilb@suse.de>
Diffstat (limited to 'drivers/md/linear.c')
-rw-r--r-- | drivers/md/linear.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/linear.c b/drivers/md/linear.c index 10748240cb2f..ec921f58fbb8 100644 --- a/drivers/md/linear.c +++ b/drivers/md/linear.c @@ -126,7 +126,7 @@ static linear_conf_t *linear_conf(mddev_t *mddev, int raid_disks) int j = rdev->raid_disk; dev_info_t *disk = conf->disks + j; - if (j < 0 || j > raid_disks || disk->rdev) { + if (j < 0 || j >= raid_disks || disk->rdev) { printk("linear: disk numbering problem. Aborting!\n"); goto out; } |