Commit a562b479 authored by Vladimir 'phcoder' Serbinenko's avatar Vladimir 'phcoder' Serbinenko
Browse files

* grub-core/disk/mdraid1x_linux.c (grub_mdraid_detect): Detect spares

	and report them as not RAID members since they are useless for GRUB.
	* grub-core/disk/mdraid_linux.c (grub_mdraid_detect): Likewise.
parent 246c2369
2011-04-06 Vladimir Serbinenko <phcoder@gmail.com>
* grub-core/disk/mdraid1x_linux.c (grub_mdraid_detect): Detect spares
and report them as not RAID members since they are useless for GRUB.
* grub-core/disk/mdraid_linux.c (grub_mdraid_detect): Likewise.
2011-04-02 Vladimir Serbinenko <phcoder@gmail.com>
 
Increase LVM implementation robustness in order not to crash on
......@@ -200,11 +200,14 @@ grub_mdraid_detect (grub_disk_t disk, struct grub_raid_array *array,
if (grub_le_to_cpu32 (real_sb->dev_number) >=
grub_le_to_cpu32 (real_sb->max_dev))
return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET,
return grub_error (GRUB_ERR_OUT_OF_RANGE,
"spares aren't implemented");
array->index = grub_le_to_cpu16
(real_sb->dev_roles[grub_le_to_cpu32 (real_sb->dev_number)]);
if (array->index >= array->total_devs)
return grub_error (GRUB_ERR_OUT_OF_RANGE,
"spares aren't implemented");
array->uuid_len = 16;
array->uuid = grub_malloc (16);
if (!array->uuid)
......
......@@ -202,7 +202,7 @@ grub_mdraid_detect (grub_disk_t disk, struct grub_raid_array *array,
"unsupported RAID level: %d", level);
if (grub_le_to_cpu32 (sb.this_disk.number) == 0xffff
|| grub_le_to_cpu32 (sb.this_disk.number) == 0xfffe)
return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET,
return grub_error (GRUB_ERR_OUT_OF_RANGE,
"spares aren't implemented");
array->name = NULL;
......
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