About the Boot Header
Bootgen attaches a boot header at the starting of any boot image. The boot header table is a structure that contains information related to booting of primary bootloader, such as the FSBL. There is only one such structure in entire boot image. This table is parsed by BootROM to get the information of where FSBL is stored in flash and where it needs to be loaded in OCM. Some encryption and authentication related parameters are also stored in here. The boot image components are:
- Zynq UltraScale+ MPSoC Boot Header, which also has the Zynq UltraScale+ MPSoC Boot Header Attribute Bits.
- Zynq UltraScale+ MPSoC Register Initialization Table
- Zynq UltraScale+ MPSoC PUF Helper Data
- Zynq UltraScale+ MPSoC Image Header Table
- Zynq UltraScale+ MPSoC Image Header
- Zynq UltraScale+ MPSoC Authentication Certificates
- Zynq UltraScale+ MPSoC Partition Header
BootROM uses the boot header to find the location and length of FSBL and other details to initialize the system before handing off the control to FSBL. The following table provides the address offsets, parameters, and descriptions for the Zynq® UltraScale+™ MPSoC device.
|0x00-0x1F||Arm® vector table||XIP ELF vector table:
|0x20||Width Detection Word||This field is used for QSPI width detection.
|0x24||Header Signature||Contains 4 bytes
|0x2C||FSBL Execution address (RAM)||FSBL execution address in OCM or XIP base address.|
|0x30||Source Offset||If no PMUFW, then it is the start offset of FSBL. If PMUFW, then start of PMUFW.|
|0x34||PMU Image Length||PMU firmware original image length in bytes. (0-128KB).
|0x38||Total PMU FW Length||Total PMUFW image length in bytes.(PMUFW length + encryption overhead)|
|0x3C||FSBL Image Length||Original FSBL image length in bytes. (0-250KB). If 0, XIP bootimage is assumed.|
|0x40||Total FSBL Length||FSBL image length + Encryption overhead of FSBL image + Auth. Cert., + 64byte alignment + hash size (Integrity check).|
|0x44||FSBL Image Attributes||See Bit Attributes.|
|0x48||Boot Header Checksum||Sum of words from offset 0x20 to 0x44 inclusive. The words are assumed to be little endian.|
|0x4C-0x68||Obfuscated/Black Key Storage||Stores the Obfuscated key or Black key.|
|0x70 -0x94||User-Defined Fields (UDF)||40 bytes.|
|0x98||Image Header Table Offset||Pointer to Image Header Table.|
|0x9C||Partition Header Table Offset||Pointer to Partition Header.|
|0xA0-0xA8||Secure Header IV||IV for secure header of bootloader partition.|
|0x0AC-0xB4||Obfuscated/Black Key IV||IV for Obfuscated or Black key.|