diff --git a/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L552xx/TOOLCHAIN_GCC_ARM/stm32l552xx.ld b/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L552xx/TOOLCHAIN_GCC_ARM/stm32l552xx.ld index fd05c82aaf..214dccf361 100644 --- a/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L552xx/TOOLCHAIN_GCC_ARM/stm32l552xx.ld +++ b/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L552xx/TOOLCHAIN_GCC_ARM/stm32l552xx.ld @@ -111,10 +111,7 @@ SECTIONS } > FLASH __exidx_end = .; - /* Location counter can end up 2byte aligned with narrow Thumb code but - __etext is assumed by startup code to be the LMA of a section in RAM - which must be 8-byte aligned */ - __etext = ALIGN (8); + __etext = .; _sidata = .; .data : AT (__etext) diff --git a/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L562xx/TOOLCHAIN_GCC_ARM/stm32l562xx.ld b/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L562xx/TOOLCHAIN_GCC_ARM/stm32l562xx.ld index fd05c82aaf..214dccf361 100644 --- a/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L562xx/TOOLCHAIN_GCC_ARM/stm32l562xx.ld +++ b/targets/TARGET_STM/TARGET_STM32L5/TARGET_STM32L562xx/TOOLCHAIN_GCC_ARM/stm32l562xx.ld @@ -111,10 +111,7 @@ SECTIONS } > FLASH __exidx_end = .; - /* Location counter can end up 2byte aligned with narrow Thumb code but - __etext is assumed by startup code to be the LMA of a section in RAM - which must be 8-byte aligned */ - __etext = ALIGN (8); + __etext = .; _sidata = .; .data : AT (__etext)