MBR detection
No
Yes
Yes
Yes
Yes
No
No
0xAA55 signature
at offset 0x01FE?
Partition type is 0x00?
Are all fields 0x00?
Is partition within
physical boundaries?
Failed
Success
init-028
For all 4 entries
No
Public Version
Device Initialization by ROM Code
www.ti.com
Figure 26-30. MBR Detection Procedure
Step 2.
Get the MBR partition:
Once identified, the ROM code gets the partition using the procedure described in
. The
partition type is checked to be FAT12/16 or FAT32. Its state must be 00h (inactive) or 80h (active.) The
ROM code returns with FAIL if no active primary FAT12/16/32 is found, or if there is more than one
active partition, the test fails. If an active partition is found, its first sector is read and used later. If no
MBR is present (in case of a floppy-like system), the first sector of the booting device is read and used
later. The read sector is checked to be a valid FAT12/16 or FAT32 partition. If this fails, if another
partition type is used (for instance, Linux FS) or if the partition is not valid, the ROM code returns with
FAIL.
The FAT file system consists of:
•
Boot sector, which holds the BIOS parameter block (BPB). Not all are used by the ROM code.
•
FAT, which describes the use of each cluster of the partition
•
Data area, which holds the files, directories, and root directory (for FAT12/16, the root directory has
a specific fixed location)
To check whether a sector holds a valid FAT12/16/32 partition, many fields of the boot sector (used by
all FAT types) that must have specific values are checked.
shows the process to get the
MBR partition.
3566
Initialization
SWPU177N – December 2009 – Revised November 2010
Copyright © 2009–2010, Texas Instruments Incorporated