cancel
Showing results for 
Search instead for 
Did you mean: 

Can the STM32H7x M4 core boot from SDRAM or not ?

Ibrahim Abdalkader
Associate II

According to the STM32H7's datasheet, the M4 core shouldn't be able to boot from an SDRAM memory address (because it's outside of the range 0x00000000 to 0x3FFF0000):

IbrahimAbdalkader_0-1705573213089.png

However, I found out that I can actually boot the M4 core from SDRAM, if I used the alias address at 0x70000000 (which is also outside of the range) instead of 0xC0000000. So I'm wondering if this is a documentation error, or an undocumented feature/bug that we shouldn't count on ?

 

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
FBL
ST Employee

Hello @Ibrahim Abdalkader 

The answer is next sentence. The BOOT_ADD0 / BOOT_ADD1 / BCM4_ADD0 / BCM4_ADD1 option bytes can be modified after reset in order to boot from any other boot address after next reset.

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.

View solution in original post

4 REPLIES 4
FBL
ST Employee

Hello @Ibrahim Abdalkader 

The answer is next sentence. The BOOT_ADD0 / BOOT_ADD1 / BCM4_ADD0 / BCM4_ADD1 option bytes can be modified after reset in order to boot from any other boot address after next reset.

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.

Hi @FBL Thank you very much for clarifying that! But I still don't understand why it can't boot from 0xC0000000 ? I tried but I can only boot from 0x70000000 after reset.

According to Table 6. Memory map and default device memory area attributes, you can remap to 0xD0000000 as it is considered for FMC SDRAM bank 2 in case of FMC remap. 0xC0000000 is linked to bank 1.

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.

Yes but this table seems to suggest that 0x70000000 and 0xC0000000 are both the same address for SDRAM bank1 with the default mapping.

IbrahimAbdalkader_0-1705598887789.png

Anyway, I I checked the table you mentioned and noticed 0xC0000000 has different default memory attributes, specifically Never Execute! Maybe that's why I couldn't boot from it. I will try to make it executable with the MPU later. Thanks a lot @FBL I think all my questions are answered.