soc: stm32: handle CCM in LINKER_GENERATOR
Currently, the soc/stm32/ccm.ld is not handled in CMAKE_LINKER_GENERATOR. This commit adds support, making STM32 supportable by alternative linkers such as AC6 and IAR. This commit also renames a variable to match all other LOADADDR symbols. Signed-off-by: Robin Kastberg <robin.kastberg@iar.com>
This commit is contained in:
parent
5f7713815a
commit
ddd1063715
5 changed files with 12 additions and 5 deletions
|
@ -7,7 +7,14 @@ zephyr_sources(
|
|||
soc_config.c
|
||||
)
|
||||
|
||||
zephyr_linker_sources_ifdef(CONFIG_STM32_CCM SECTIONS ccm.ld)
|
||||
if(DEFINED CONFIG_STM32_CCM)
|
||||
zephyr_linker_group(NAME CCM_REGION VMA CCM LMA ROM_REGION)
|
||||
zephyr_linker_section(NAME .ccm_bss GROUP CCM_REGION SUBALIGN 4 TYPE BSS )
|
||||
zephyr_linker_section(NAME .ccm_noinit GROUP CCM_REGION SUBALIGN 4 TYPE NOLOAD NOINIT)
|
||||
zephyr_linker_section(NAME .ccm_data GROUP CCM_REGION SUBALIGN 4)
|
||||
|
||||
zephyr_linker_sources(SECTIONS ccm.ld)
|
||||
endif()
|
||||
|
||||
zephyr_sources_ifdef(CONFIG_STM32_BACKUP_SRAM stm32_backup_sram.c)
|
||||
zephyr_linker_sources_ifdef(CONFIG_STM32_BACKUP_SRAM SECTIONS stm32_backup_sram.ld)
|
||||
|
|
|
@ -29,6 +29,6 @@ GROUP_START(CCM)
|
|||
|
||||
__ccm_end = .;
|
||||
|
||||
__ccm_data_rom_start = LOADADDR(_CCM_DATA_SECTION_NAME);
|
||||
__ccm_data_load_start = LOADADDR(_CCM_DATA_SECTION_NAME);
|
||||
|
||||
GROUP_END(CCM)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue