Commit 4d1e2bc9 authored by Vladimir 'phcoder' Serbinenko's avatar Vladimir 'phcoder' Serbinenko
Browse files

* grub-core/disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Skip

	disks with unknown size.
	* grub-core/disk/raid.c (scan_devices): Allow disks with unknown sizes.
parent 75b49ebe
2012-01-14 Vladimir Serbinenko <phcoder@gmail.com>
* grub-core/disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Skip
disks with unknown size.
* grub-core/disk/raid.c (scan_devices): Allow disks with unknown sizes.
2012-01-14 Vladimir Serbinenko <phcoder@gmail.com>
 
Remove defines pertaining to arbitrary limits not affecting GRUB
......@@ -100,8 +100,10 @@ grub_dmraid_nv_detect (grub_disk_t disk, struct grub_raid_array *array,
if (disk->partition)
return grub_error (GRUB_ERR_OUT_OF_RANGE, "skip partition");
sector = grub_disk_get_size (disk) - 2;
sector = grub_disk_get_size (disk);
if (sector == GRUB_DISK_SIZE_UNKNOWN)
return grub_error (GRUB_ERR_OUT_OF_RANGE, "not raid");
sector -= 2;
if (grub_disk_read (disk, sector, 0, sizeof (sb), &sb))
return grub_errno;
......
......@@ -131,8 +131,7 @@ scan_devices (const char *arname)
}
}
if ((disk->total_sectors != GRUB_ULONG_MAX) &&
(! raid->detect (disk, &array, &start_sector)) &&
if ((! raid->detect (disk, &array, &start_sector)) &&
(! insert_array (disk, &array, start_sector, raid->name,
raid)))
return 0;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment