SBSFU: The binary image to be installed overlap with the trailer area
Hello,
We have a software project with STM32H7B3 MCU using SBSFU for bootloader and installing updates. We are using one download slot and one active slot and have been very tight on flash size and have often had to reduce binary size. Normally, this is not a problem since we get a compilation error from the linker script when binary size becomes too big. In the linker script we have:
ISR_VECTOR_START = __ICFEDIT_SLOT_Active_1_start__ + 0x400; /* Cortex-M7: align the init vectors on 0x400 */
APP_ROM_START = ISR_VECTOR_START + VECTOR_SIZE;
APP_ROM_END = __ICFEDIT_SLOT_Active_1_end__;
APP_ROM_LENGTH = APP_ROM_END - APP_ROM_START + 1;
/* Specify the memory areas */
MEMORY
{
DTCMRAM (xrw) : ORIGIN = 0x20000000, LENGTH = 128K
RAM (xrw) : ORIGIN = 0x24000000, LENGTH = 1024K
ITCMRAM (xrw) : ORIGIN = 0x00000000, LENGTH = 64K
ISR_VECTOR (Rw) : ORIGIN = ISR_VECTOR_START, LENGTH = VECTOR_SIZE
APP_ROM (rx) : ORIGIN = APP_ROM_START, LENGTH = APP_ROM_LENGTH
}This makes APP_ROM_END equal to 0x081FFFFF and compilation should not be possible if binary grows too much. However, we have now encountered a situation where the software compiled successfully and we got a .sfb update image, which was downloaded to flash. Once, SBSFU executed, it gave the following warning:
> = [FWIMG] The binary image to be installed overlap with the trailer area!
Upon further research, I found that there is a trailer area which starts at address 0x81FF980. This is not mentioned in any documentation I could find. Could someone explain what is the trailer area and should I change APP_ROM_END to 0x81FF97F so that there is no overlap? This seems weird since none of the SBSFU example projects seem to take the trailer area into consideration.

