arm: linker.ld: Port KINETIS_FLASH_CONFIG to zephyr_linker_sources()
Add the .kinetis_flash_config via its own linker script snippet. Signed-off-by: Øyvind Rønningstad <oyvind.ronningstad@nordicsemi.no>
This commit is contained in:
parent
321462b310
commit
f5fda5cfa1
4 changed files with 16 additions and 11 deletions
|
@ -161,12 +161,6 @@ SECTIONS
|
|||
*/
|
||||
#include <snippets-text-start.ld>
|
||||
|
||||
#ifdef CONFIG_KINETIS_FLASH_CONFIG
|
||||
. = CONFIG_KINETIS_FLASH_CONFIG_OFFSET;
|
||||
KEEP(*(.kinetis_flash_config))
|
||||
KEEP(*(".kinetis_flash_config.*"))
|
||||
#endif
|
||||
|
||||
} GROUP_LINK_IN(ROMABLE_REGION)
|
||||
|
||||
#ifdef CONFIG_CODE_DATA_RELOCATION
|
||||
|
|
|
@ -158,11 +158,6 @@ SECTIONS
|
|||
*/
|
||||
#include <snippets-text-start.ld>
|
||||
|
||||
/* Kinetis has to write 16 bytes at 0x400 */
|
||||
SKIP_TO_KINETIS_FLASH_CONFIG
|
||||
KEEP(*(.kinetis_flash_config))
|
||||
KEEP(*(".kinetis_flash_config.*"))
|
||||
|
||||
} GROUP_LINK_IN(ROMABLE_REGION)
|
||||
|
||||
#ifdef CONFIG_CODE_DATA_RELOCATION
|
||||
|
|
|
@ -3,3 +3,9 @@
|
|||
zephyr_sources_ifdef(CONFIG_KINETIS_FLASH_CONFIG flash_configuration.c)
|
||||
|
||||
add_subdirectory(${SOC_SERIES})
|
||||
|
||||
zephyr_linker_sources_ifdef(CONFIG_KINETIS_FLASH_CONFIG
|
||||
TEXT_START
|
||||
SORT_KEY ${CONFIG_KINETIS_FLASH_CONFIG_OFFSET}
|
||||
flash_config.ld
|
||||
)
|
||||
|
|
10
soc/arm/nxp_kinetis/flash_config.ld
Normal file
10
soc/arm/nxp_kinetis/flash_config.ld
Normal file
|
@ -0,0 +1,10 @@
|
|||
/*
|
||||
* Copyright (c) 2019 NXP
|
||||
* Copyright (c) 2019 Nordic Semiconductor ASA
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
. = CONFIG_KINETIS_FLASH_CONFIG_OFFSET;
|
||||
KEEP(*(.kinetis_flash_config))
|
||||
KEEP(*(".kinetis_flash_config.*"))
|
Loading…
Add table
Add a link
Reference in a new issue