Hacker News new | ask | show | jobs
by blueflow 977 days ago
> GPT/UEFI are standards, they are not ruled by Microsoft

- GPT partition uuid's with the "mixed endianess" from Windows COM: https://devblogs.microsoft.com/oldnewthing/20220928-00/?p=10...

- ESP is the FAT filesystem, developed in 1977 for DOS

- LFS vfat extensions so the ESP can have directory entries with lowercase letters or longer than 11 characters. This also pulls in the UCS-2 encoding. Stuff from Windows 95.

- EFI executables are actually windows PE executables

- ... which are hacked on top of a MS-DOS MZ executables (The "This program cannot be run in DOS mode" thing)

- ... and use the Windows64 calling convention

So formally, UEFI is not ruled by Microsoft. Somehow yet all this Windows/MS-DOS stuff ended up in it.

1 comments

>GPT partition uuid's with the "mixed endianess" from Windows COM

From the wikipedia[1]:

>The binary encoding of UUIDs varies between systems. Variant 1 UUIDs, nowadays the most common variant, are encoded in a big-endian format.

>Variant 2 UUIDs, historically used in Microsoft's COM/OLE libraries, use a little-endian format, but appear mixed-endian with the first three components of the UUID as little-endian and last two big-endian, due to the missing byte dashes when formatted as a string

In other words, there are 2 variants, 2 is for Microsoft's COM/OLE, so it's not designed by Microsoft.

>ESP is the FAT filesystem, developed in 1977 for DOS

>LFS vfat extensions so the ESP can have directory entries with lowercase letters or longer than 11 characters. This also pulls in the UCS-2 encoding. Stuff from Windows 95.

FAT is not govern by Microsoft, despite them being the original author, and even then FAT32 patents have expired[2].

>EFI executables are actually windows PE executables

You would need to provide proper source for this, the only source I can only talks about boot loaders, which I would imagine is written with the OS in mind[3].

[1]https://en.wikipedia.org/wiki/Universally_unique_identifier#...

[2]https://en.wikipedia.org/wiki/File_Allocation_Table#Patents

[3]https://en.wikipedia.org/wiki/UEFI#Applications

You are wrong on the UUIDs, Variant 2 is what Microsoft did and got standardized after the fact.

And here the history and current usage of the PE format: https://en.wikipedia.org/wiki/Portable_Executable

It was made for Windows 3.1.

If you read my comment or the Wikipedia page you'll see clear as day that varient 2 is meant for windows, so I dont get this correction.

And again that source doesn't give me any evidence of your claim.