2025-10-11 12:45 AM - last edited on 2025-10-13 7:02 AM by Andrew Neil
Hi ST Community,
I'm working with a custom board based on the STM32MP257F and using the stm32mp257f-ev1.dts as the base device tree for development.
After flashing the firmware and booting the board, I'm encountering a DDR initialization failure during the BL2 stage. Here's a snippet from the boot log (via UART, Docklight):
ERROR: ddrphy_phyinit_usercustom_g_waitfwdone Training has failed.ERROR: DDR PHY init: Error -1 BACKTRACE: START: stm32mp2_ddr_init
PANIC at PC : 0x0000000000e01f9fc
The specific error seems related to DDR PHY training failure:
ERROR: ddrphy_phyinit_usercustom_g_waitfwdone Training has failed.
We're using DDR4 2x16Gbits @ 1200MHz as indicated in the log:
and attached a image of boot log and the error what we are getting while booting with custom board, but boots successfully with stm32mp257f-ev1.
i performed the DDR utility test on the custom board , the image of ddr test report also attached for you reference
how can i rectify this issue
2025-10-13 6:56 AM
Hi @srinivas_mv
If STM32DDRFW-UTIL run without issue, maybe double check:
Regards.
2025-10-17 2:10 AM
Yes we are also getting same problem, The board is passing utility but unable to boot. Getting ddr_training failure.
Can you help out us to identify the problem. The image is booting on evaluation board. Our custom board is having same hardware connections as evaluation board STM32MP257EV1. And the supplies lines are fine while booting.
2025-10-17 3:54 AM
Hi,
maybe look deeper on potential delta between your custom board and EV1 board.
Even tiny change versus reference board could make big differences if not mastered.
For instance, please check potential supplies, DDR4 reference or control signals which might take longer time to stabilize upon reset or when enabled by the SW.
Check also HSE crystal which might take longer time to start oscillating correctly.
As STM32DDRFW-UTIL is interactive, there is much more time in between actions than in TF-A which make all in a row within a short time.
Are you using recommended components en layout around STPMIC25 ?
Are you using recommended layout between STM32MP257FAI and DDR4 devices ?
Regards.
2025-10-17 4:23 AM
Hi ,
Thanks for the reply, We are using recommended components en layout around STPMIC25.
We have followed the guidelines provided by ST for layout between STM32MP257FAI and DDR4 devices..The hardware design is same for ddr for EV1 and our custom board.
