Skip to content

Commit fa64761

Browse files
haduongquangfabiobaltieri
authored andcommitted
arch: arm: cortex_m: linker: fix mpu setup failure when XIP disabled
Add a padding section after the final read only data section to avoid overlap between ROMABLE_REGION and RAMABLE_REGION. Signed-off-by: Ha Duong Quang <[email protected]>
1 parent b3be861 commit fa64761

File tree

1 file changed

+1
-1
lines changed
  • include/zephyr/arch/arm/cortex_m/scripts

1 file changed

+1
-1
lines changed

include/zephyr/arch/arm/cortex_m/scripts/linker.ld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ SECTIONS
225225

226226
#include <zephyr/linker/cplusplus-rom.ld>
227227

228-
#if defined(CONFIG_BUILD_ALIGN_LMA)
228+
#if defined(CONFIG_BUILD_ALIGN_LMA) || !defined(CONFIG_XIP)
229229
/*
230230
* Include a padding section here to make sure that the LMA address
231231
* of the sections in the RAMABLE_REGION are aligned with those

0 commit comments

Comments
 (0)