[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-xorriso] [bug #46716] Protective MBR partition is not marked as

From: Andrei Borzenkov
Subject: Re: [Bug-xorriso] [bug #46716] Protective MBR partition is not marked as bootable
Date: Sun, 20 Dec 2015 10:18:47 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0

19.12.2015 22:37, Thomas Schmitt пишет:
> Hi,
> Andrei Borzenkov wrote:
>> a) are we sure every EFI system out there accepts MBR (Apple?)
> At least my favorite layout (see my recent mail
> address@hidden) is explicitely
> promised by UEFI 2.4, "5.2.1 Legacy Master Boot Record (MBR)".

"promised" is encouraging :)

>> b) GPT has nice feature of self-identifying block size.
> How this ?
> There are no block size fields in the GPT storage format.

GPT starts at LBA 1. So we can deduce block size used to create this GPT
by checking location of GPT header. This allows GRUB to compute correct
GPT partitions offset and size when accessing image as CD-ROM with block
size 2KiB even though partition is created with 512B block size.

Another use case is disk partition in 512e mode but accessed in 4Kn mode
(or vice versa).

But I am not aware of anyone else using the same technique. Everyone
else just assumes GPT matches block size device reports.

> UEFI 2.4, 5.3.1 frightens me by
>   "The device may present a logical block size that is not 512 bytes long."
> which would not play well with our habit to create image files
> which only later get onto some device.

Yes. As soon as 4Kn USB sticks appear grub-mkrescue images stop to work
for hybrid boot unless we also create second GPT at 4K offset (I do not
think any BIOS works in 4Kn mode, so here it should remain OK).

> i wrote:
>>> Nevertheless, your overlapping layout would have the appeal of
>>> giving a mountable partition:
>>> [...]
>>> It would travel on the ticket that EFI shall ignore MBR partition
>>> type 0x00.
>> I'm not sure where this assumptions comes from. EFI does not say
>> anything about other partition types,
> UEFI 2.4, 5.2.1 Legacy Master Boot Record (MBR)
>   "A Partition Record that contains an OSType value of zero or a
>    SizeInLBA value of zero may be ignored."
> Table 14 shows OSType as byte at offset 4 in the MBR partition
> entry. Aka "partition type".

Please do not confuse MBR support and protective MBR definition. I
replied in context of protective MBR, and protective MBR is not supposed
to contain any other partition besides 0xee.

> The question is how far this ignoring goes.
> ishoybrid+GRUB2 as of mjg hopes for effective non-existence
> as far as EFI and its do-not-overlap demand is concerned.

Not sure I can parse this sentence :) But it looks like hybrid MBR is
the only solution. The question is how partition layout should look like.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]