2025-05-07 5:24 AM - last edited on 2025-05-07 5:31 AM by Andrew Neil
Hi,
we are developping a projet with TFM activated on STMU585 device (by the way, we don't really need the full TFM but at least Secure boot and SBSFU). We would want to declare a Flash page to store some configurations parameters, so we created a dedicated page for these data in the memory mapping.
But I would want to know if it's allowed for the embedded user application code to write on this page without violating TFM rules. Or if have to use the SBSFU + teraterm (etc..) to update these configuration parameters.
Another question linked to the previous one, once the TFM is activated the complete memory seems to be used (from HASH REF to Local Loader memory area) so the 2 MB are allocated.
Is it possible to reduce the complete footprint and keep some memory pages free to put some data out of the TFM control ?
I didn't find these informations in the UM2851
Thanks in advance for your support.
C.S.
2025-05-07 10:05 AM
Hello @CS83 ,
if you don't need TFM please use STM32Cube_FW_U5_V1.7.0\Projects\B-U585I-IOT02A\Applications\SBSFU\ project that is only the secure boot part.
You can reserve one or several flash sectors not managed by the secure boot.
Only active and download slots are handled.
To configure the secure boot sizes you need to adapt the flash_layout.h located in Linker folder.
This is not that easy unfortunately.
Basically you have:
#define FLASH_S_PARTITION_SIZE (0x06000)
#define FLASH_NS_PARTITION_SIZE (0xA0000) /* 640 KB for NS partition */ (in case of STM32U585)
that have to be adapted.
Best regards
Jocelyn