diff --git a/core/cortex-m/ec.lds.S b/core/cortex-m/ec.lds.S index dc9e829fa1..d0b90e5ada 100644 --- a/core/cortex-m/ec.lds.S +++ b/core/cortex-m/ec.lds.S @@ -68,6 +68,9 @@ SECTIONS } > SHARED_LIB #endif .text : { +#if defined(CONFIG_RO_HEAD_ROOM) + . = . + CONFIG_RO_HEAD_ROOM; +#endif OUTDIR/core/CORE/init.o (.text.vecttable) . = ALIGN(4); __version_struct_offset = .; diff --git a/include/config.h b/include/config.h index a527c67fed..b718941a12 100644 --- a/include/config.h +++ b/include/config.h @@ -1820,6 +1820,12 @@ */ #undef CONFIG_WP_ALWAYS +/* + * If needed to allocate some free space in the base of the RO section of the + * image, define this to be equal the required size of the free space. + */ +#undef CONFIG_RO_HEAD_ROOM + /*****************************************************************************/ /* * Include board and core configs, since those hold the CONFIG_ constants for a