Remove data member in partition structure
This commit is contained in:
parent
35b86ff407
commit
58548abbc3
8 changed files with 13 additions and 25 deletions
|
@ -130,17 +130,21 @@ setup (const char *dir,
|
|||
int NESTED_FUNC_ATTR find_usable_region_gpt (grub_disk_t disk __attribute__ ((unused)),
|
||||
const grub_partition_t p)
|
||||
{
|
||||
struct grub_gpt_partentry *gptdata = p->data;
|
||||
struct grub_gpt_partentry gptdata;
|
||||
|
||||
disk->partition = p->parent;
|
||||
if (grub_disk_read (disk, p->offset, p->index,
|
||||
sizeof (gptdata), &gptdata))
|
||||
return 0;
|
||||
|
||||
/* If there's an embed region, it is in a dedicated partition. */
|
||||
if (! memcmp (&gptdata->type, &grub_gpt_partition_type_bios_boot, 16))
|
||||
if (! memcmp (&gptdata.type, &grub_gpt_partition_type_bios_boot, 16))
|
||||
{
|
||||
embed_region.start = p->start;
|
||||
embed_region.end = p->start + p->len;
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue