Visible to Intel only — GUID: jto1540272334080
Ixiasoft
Visible to Intel only — GUID: jto1540272334080
Ixiasoft
3.2.4.1. Absolute Application Image Layout
This section presents the layout of an absolute application image. Starting with Quartus version 21.1 relative images were introduced, and the absolute images are now deprecated. It is recommended to only use relative images.
The application image comprises SDM firmware and the configuration data. The configuration data includes up to four sections. The SDM firmware contains pointers to those sections. The table below shows the location of the number of sections and the section pointers in a application image.
Offset | Size (in bytes) | Description |
---|---|---|
0x1F00 | 4 | Number of sections |
… | ||
0x1F08 | 8 | Address of 1st section |
0x1F10 | 8 | Address of 2nd section |
0x1F18 | 8 | Address of 3rd section |
0x1F20 | 8 | Address of 4th section |
… | ||
0x1FFC | 4 | CRC32 of 0x1000 to 0x1FFB |
The section pointers must match the actual location of the FPGA image in flash. Two options are available to meet this requirement:
- You can generate the application image to match the actual location in quad SPI flash memory. This option may not be practical as different systems may have a different set of updates applied, which may result in different slots being suitable to store the new application image.
- You can generate the application image as if it is located at address zero by passing the “-o start_address=0x0” option to the Programming File Generator, then update the pointers to match the actual location.
When using the HPS to manage RSU, both U-Boot and LIBRSU clients implement the below procedure to relocate application images targeting address zero in the actual destination slot address.
- Create the application image, targeting the INITIAL_ADDRESS.
- Read the 32-bit value from offset 0x1F00 of the application image to determine the number of sections.
- For <s>= 1 to number_of_sections:
- section_pointer = read the 64-bit section pointer from 0x1F00 + (s * 8)
- Subtract INITIAL_ADDRESS from section_pointer
- Add NEW_ADDRESS to section_pointer
- Store updated section_pointer
- Recompute the CRC32 for addresses 0x1000 to 0x1FFB. Store the new value at offset 0x1FFC. The CRC32 value must be computed on a copy of the data using the following procedure:
- Swap the bits of each byte so that the bits occur in reverse order and compute the CRC.
- Swap the bytes of the computed CRC32 value to appear in reverse order.
- Swap the bits in each byte of the CRC32 value.
- Write the CRC32 value to flash.