drivers/ata/bios.c File Reference


Detailed Description

This communication driver does all accesses to the boot medium via 16 bit real mode calls into the standard BIOS. Due to this method, its possible to use all the medias to boot from that are supported by the BIOS. This also includes emulated only medias.

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!


Defines

#define SECTORS_AT_ONCE   64


Define Documentation

#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.

Todo:
127 are always possible, some BIOS manufacturer supports up to 255. Is it's worth to detect Phoenic's restriction?


Variable Documentation

struct DAPS packed

"Disk Address Packet Structure" to be used when calling BIOS's int13, function 0x42/0x43


Generated on Thu Mar 3 16:07:06 2011 for barebox by  doxygen 1.5.6