Part Number: TMS320F28377D
Other Parts Discussed in Thread: C2000WARE
I have to following issue with the secure mode on the F28377D.
I have enabled the DCSM and secured all my Flash and RAMs. I have allocated my stack to a secure RAM. The AdcSetMode function in F2837xD_ADC.c calls into the TI OTP Flash – functions CalAdcaINL, CalAdcbINL, CalAdccINL, CalAdcdINL, and GetAdcOffsetTrimOTP. I suspect these functions then call into the Boot ROM, though I have not verified this. The Boot ROM cannot be secured. This results in the unsecured Boot ROM functions using a stack in secure RAM - reads from the stack return zero and writes to the stack are ignored.
What strategy do you recommend for calling functions in unsecured memory with a stack in secured RAM. Moving the whole stack to unsecured memory is not really an option – I want my stack secured. My initial idea is to switch to an unsecured stack, with interrupts disabled, for the duration of the function call – I am not calling these unsecured functions from multiple execution contexts so this is safe. Are there any other options available to me, e.g. obtaining the source for those functions stored in unsecured ROM and building them into my secured Flash?
Regards, Bernd