I'm configuring the FlexRAM on our chip to all 16 banks of OCRAM by writing to the IOMUXC_GPR registers in the startup code. This successfully flashes over JLink and runs. However, when trying to flash again, I must now hold reset on the device before JLink can download the new file. What is causing this? Does JLink need some DTCM or ITCM memory?
Downloading file [./build/debug/image.hex]...
****** Error: Failed to prepare for programming.
Could not preserve target memory.
Error while determining flash info (Bank @ 0x60000000)
Unspecified error -1
IOMUXC_GPR_GPR17 = 0x55555555 // Set all banks to OCRAM
IOMUXC_GPR_GPR16 &= ~0x3 // Disable ITCM and DTCM
IOMUXC_GPR_GPR16 |= 0x4 // Set FlexRAM Allocation to BankCfg