Skip to main content
kiichi
Associate III
January 19, 2024
Question

BL32 does not start

  • January 19, 2024
  • 2 replies
  • 8782 views

Custom STM32MP151A board with 512MB DDR2.

I am trying to write via UART communication with STM32CubeProgrammer, but BL32 processing does not start.

What should I do to investigate the cause?

 

[2024-01-12 14:11:52.591] NOTICE: CPU: STM32MP151AAC Rev.Z
[2024-01-12 14:11:52.591] NOTICE: Model: STMicroelectronics custom STM32CubeMX board - openstlinux-5.15-yocto-kirkstone-mp1-v22.11.23
[2024-01-12 14:11:52.623] INFO: PMIC version = 0x21
[2024-01-12 14:11:52.623] WARNING: VDD unknown
[2024-01-12 14:11:52.623] INFO: Reset reason (0x14):
[2024-01-12 14:11:52.696] INFO: Pad Reset from NRST
[2024-01-12 14:11:52.696] INFO: FCONF: Reading TB_FW firmware configuration file from: 0x2ffe2000
[2024-01-12 14:11:52.696] INFO: FCONF: Reading firmware configuration information for: stm32mp_io
[2024-01-12 14:11:52.696] INFO: Using UART
[2024-01-12 14:11:52.696] INFO: Instance 8
[2024-01-12 14:11:52.696] INFO: Boot used partition fsbl1
[2024-01-12 14:11:52.696] NOTICE: BL2: v2.6-stm32mp1-r2.0(debug):v2.6-dirty(a1f02f4f)
[2024-01-12 14:11:52.696] NOTICE: BL2: Built : 13:14:26, Nov 23 2021
[2024-01-12 14:11:52.696] INFO: BL2: Doing platform setup
[2024-01-12 14:11:52.696] INFO: RAM: LPDDR2 32bits 360000kHz
[2024-01-12 14:11:52.696] INFO: Memory size = 0x20000000 (512 MB)
[2024-01-12 14:11:52.711] INFO: UART: read phase 3 at 0xc7000000 size 0x1000000
[2024-01-12 14:13:19.102] WARNING: UART: Bad packet number receive: 13500416, expected 1331
[2024-01-12 14:14:04.514] WARNING: UART: Bad packet number receive: 13500416, expected 2039
[2024-01-12 14:16:39.908] INFO: UART: Start phase 3
[2024-01-12 14:16:40.047] INFO: BL2: Loading image id 1
[2024-01-12 14:16:40.047] INFO: Loading image id=1 at address 0x2ffff000
[2024-01-12 14:16:40.047] INFO: Image id=1 loaded: 0x2ffff000 - 0x2ffff226
[2024-01-12 14:16:40.047] INFO: FCONF: Reading FW_CONFIG firmware configuration file from: 0x2ffff000
[2024-01-12 14:16:40.047] INFO: FCONF: Reading firmware configuration information for: dyn_cfg
[2024-01-12 14:16:40.047] INFO: FCONF: Reading firmware configuration information for: stm32mp1_firewall
[2024-01-12 14:16:40.047] INFO: BL2: Loading image id 4
[2024-01-12 14:16:40.047] INFO: Loading image id=4 at address 0x2ffc5000
[2024-01-12 14:16:40.047] INFO: Image id=4 loaded: 0x2ffc5000 - 0x2ffd9820
[2024-01-12 14:16:40.047] INFO: BL2: Skip loading image id 8
[2024-01-12 14:16:40.047] INFO: BL2: Skip loading image id 9
[2024-01-12 14:16:40.047] INFO: BL2: Loading image id 2
[2024-01-12 14:16:40.047] INFO: Loading image id=2 at address 0xc0500000
[2024-01-12 14:16:40.047] INFO: Image id=2 loaded: 0xc0500000 - 0xc0511688
[2024-01-12 14:16:40.047] INFO: BL2: Loading image id 16
[2024-01-12 14:16:40.047] INFO: Loading image id=16 at address 0x2ffc0000
[2024-01-12 14:16:40.047] INFO: Image id=16 loaded: 0x2ffc0000 - 0x2ffc4039
[2024-01-12 14:16:40.047] INFO: BL2: Loading image id 5
[2024-01-12 14:16:40.047] INFO: Loading image id=5 at address 0xc0100000
[2024-01-12 14:16:40.047] INFO: Image id=5 loaded: 0xc0100000 - 0xc01ece88
[2024-01-12 14:16:40.048] NOTICE: BL2: Booting BL32
[2024-01-12 14:16:40.048] INFO: Entry point address = 0x2ffc5000
[2024-01-12 14:16:40.048] INFO: SPSR = 0x1d3
[2024-01-12 14:16:40.284] PANIC at PC : 0x2ffc98b1
[2024-01-12 14:16:40.284]
[2024-01-12 14:16:40.284] Exception mode=0x00000016 at: 0x2ffc98b1

2 replies

PatrickF
Technical Moderator
January 19, 2024

Usually this is due to DDR not working (missing HSE, missing supplies, bad configuration, PCB issues, etc...).

To test DDR, please have a look to
https://wiki.st.com/stm32mpu/wiki/STM32DDRFW-UTIL

Regards.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.NEW ! Sidekick STM32 AI agent, see here
kiichi
kiichiAuthor
Associate III
January 19, 2024

BL32 is located from address 0x2ffc500, so I guess it has nothing to do with DDR ?.

PatrickF
Technical Moderator
January 19, 2024

Is, but as far as I know, BL32 is in charge of initializing the DDR and loading uBoot on it.
https://wiki.st.com/stm32mpu-ecosystem-v4/wiki/Boot_chain_overview#Overview_2

 

It is anyway highly recommended to ensure DDR is working (using DDRFWUTIL) as first step during board bring up.

Regards.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.NEW ! Sidekick STM32 AI agent, see here
kiichi
kiichiAuthor
Associate III
August 11, 2024

The problem was solved by deleting "vtt_ddr" from the PMIC setting in the OPTEE device tree.

Thanks

Kiichi

Lead
August 11, 2024

@kiichi 

How can you even boot if you're missing vtt_ddr?

Sounds weird, because when I missed vtt_ddr, then I could not boot the first .stm32 file in CubeProg

STM32MP151AAC3 custom board with STM32-OS as operating system: https://github.com/DanielMartensson/STM32-ComputerSTM32MP257FAK3 custom board with STM64-OS as operating system: https://github.com/DanielMartensson/STM64-Computer