Comments on Writing Boot Sector Code

non-entity said:

Boot sector programming has always seemed like one of the cooler ways to play with writing lower level code, but am I wrong to assume it won't work on systems with UEFI?

leo89 said:

It may work with UEFI if it's set to compatibility mode.

Masud Rahman said:

That's correct. UEFI firmware will execute a PE image (the same format that Windows executables use) on a FAT32 file system, and can access UEFI services to execute a kernel.

The UEFI firmware may support a CSM (compatibility support module) that can boot a legacy BIOS loader.

Randall Degges said:

This is a great introduction to writing boot sector code! Really brings back memories. So awesome.