STM32N657-DK: BootROM hangs after reset if XSPI1 has been initialized (power cycle required)
Hello,
I am experiencing what appears to be a BootROM or silicon issue on the STM32N657-DK.
Hardware
- STM32N657-DK Discovery board
- Boot from the on-board XSPI Flash
- External APSRAM connected to XSPI1
Problem description
The system works perfectly after a power-on reset.
The FSBL starts correctly, the application runs, XSPI1 is initialized, and the APSRAM is fully functional. There are no communication errors with the memory.
However, after XSPI1 has been initialized once, any subsequent reset causes the board to become completely unresponsive.
The problem occurs with:
- pressing the NRST button,
- calling NVIC_SystemReset(),
- or resetting through the debugger.
After such a reset:
- the CPU never reaches the FSBL,
- the debugger cannot stop in the reset handler,
- it appears that the BootROM itself never starts the boot process.
The only way to recover the board is to completely remove the power supply and power it up again. A simple reset is never sufficient.
Additional observations
- If XSPI1 is never initialized, the board can be reset indefinitely without any issue.
- The problem only appears after XSPI1 has been configured and used.
- The APSRAM itself operates correctly while the application is running.
- Therefore, this does not appear to be an APSRAM communication problem.
Related information
I found a discussion on the ST Community that describes almost exactly the same behavior:
- first boot after power-on works,
- after XSPI1 initialization, any reset prevents the BootROM from starting,
- only a complete power cycle restores normal operation.
The discussion also mentions Errata ES0620, section 2.2.23, concerning modifications of RCC clock selection registers (CCIPR6/7/8/13), which may prevent the BootROM from booting correctly after a reset.
Questions
Is this a known BootROM limitation or silicon issue?
Is there an official workaround besides avoiding modifications of the XSPI kernel clock selection?
Is this issue fixed in a newer silicon revision or BootROM version?
Any information would be greatly appreciated.
Thank you.
Edo
