This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
What are the important steps that needs to be considered to create a ROM compatible image ?
How to run and debug an HSM Run Time image using CCS and XDS debugger ?
What are the changes required for SBL for Custom HSM Run Time Firmware ?
What are the basic requirements of HSM Run Time Firmware during initialization time of Custom HSM Run Time Firmware ?
NOTE : For accessing the links mentioned in this thread, you must have an NDA and MySecureSW access.
What are the important steps that needs to be considered to create a ROM compatible image ?
The steps of creating a ROM compatible image is mentioned here -
The customer HSM firmware should be available in a format where it can be converted into Raw Binary format. If the build system from custom HSM firmware does not use tiarmclang as compiler, it is preferred to use the same compiler tools to extract the bin file.
The binary file should not exceed in size - AM263x : The max size supported is 184KB.
Success criterion -
In the startup of custom HSM firmware - try writing in the public core accessible memory and keep the core in infinite loop after the same. Check this value after SBL successfully installs the custom HSM Firmware (mentioned in Q3).
Note : To verify this step, the SBL certificate must have a debug extension with debug options as Public Enable.
How to run and debug an HSM Run Time image using CCS and XDS debugger ?
On HS-SE devices, the debug is closed for HSM as well as R5F Application cores. There are 2 ways to open the debug.
To debug TIFS-MCU or R5F Applications in case of HS-SE devices, here is an FAQ - https://e2e.ti.com/support/microcontrollers/arm-based-microcontrollers-group/arm-based-microcontrollers/f/arm-based-microcontrollers-forum/1194740/faq-am2634-faq-how-to-debug-tifs-mcu-for-cortex-m4-on-am263x-am273x
However this method works for TIFS-MCU but might not work for custom HSM firmware. The customer HSM Firmware might not support the same debug authentication mechanism as TIFS-MCU.
Hence, accessing the HSM firmware for development purpose has to be done via directly accessing the secure manager's debug registers.
Simple Steps -
Success criterion -
Try connecting to HSM cores as well as the R5F cores.
Note : To verify this step, the SBL certificate must not have a debug extension at all.
What are the changes required for SBL for Custom HSM Run Time Firmware ?
There are required changes in the hsmclient_loadhsmrt.c (SDK/source/drivers/hsmclient/soc/am263x/hsmclient_loadhsmrt.c)
Hsmclient_loadHSMRtFirmware - This API is responsible for installing the HSM Firmware by using the ROM service. This API also waits till TIFS Initializations are completed and sends a Notification Message to HSMClient.
Success criterion -
What are the basic requirements of HSM Run Time Firmware during initialization time of Custom HSM Run Time Firmware ?