To be able to call the real mode BIOS, this driver must switch back to real mode for each access. This will slow down the access a little bit, but we are a boot loader here, not an operating system...
Note: We need scratch memory for the BIOS communication, because the BIOS can only handle memory below 0xA0000. So we must copy all data between the flat mode buffers and realmode buffers.
Note: This driver makes no sense on other architectures than x86.
Note: This driver does only support LBA addressing. Currently no CHS!
|#define BIOS_READ_CMD 0|
Command to read sectors from media.
|#define BIOS_WRT_CMD 1|
Command to write sectors to media.
|#define SECTOR_SIZE 512|
Size of one sector in bytes.
|#define SECTORS_AT_ONCE 64|
Sector count handled in one count.
|struct DAPS packed|
"Disk Address Packet Structure" to be used when calling BIOS's int13, function 0x42/0x43