arm: Convert DT_CCM_* to new devicetree.h macros
Convert various DT_CCM_* macros to use DT_CHOSEN(zephyr_ccm) and associated macros from devicetree.h. We remove CCM references from cortex_a and cortex_r linker scripts as its only a feature on Cortex-M STM32 SoCs. Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
parent
a49817d17e
commit
9b4298c20d
|
@ -81,9 +81,6 @@ _region_min_align = 4;
|
|||
MEMORY
|
||||
{
|
||||
FLASH (rx) : ORIGIN = ROM_ADDR, LENGTH = ROM_SIZE
|
||||
#ifdef DT_CCM_BASE_ADDRESS
|
||||
CCM (rw) : ORIGIN = DT_CCM_BASE_ADDRESS, LENGTH = DT_CCM_SIZE * 1K
|
||||
#endif
|
||||
SRAM (wx) : ORIGIN = RAM_ADDR, LENGTH = RAM_SIZE
|
||||
/* Used by and documented in include/linker/intlist.ld */
|
||||
IDT_LIST (wx) : ORIGIN = (RAM_ADDR + RAM_SIZE), LENGTH = 2K
|
||||
|
|
|
@ -95,8 +95,8 @@ MEMORY
|
|||
#ifdef CONFIG_HAS_TI_CCFG
|
||||
FLASH_CCFG (rwx): ORIGIN = CCFG_ADDR, LENGTH = CCFG_SIZE
|
||||
#endif
|
||||
#ifdef DT_CCM_BASE_ADDRESS
|
||||
CCM (rw) : ORIGIN = DT_CCM_BASE_ADDRESS, LENGTH = DT_CCM_SIZE * 1K
|
||||
#if DT_HAS_NODE(DT_CHOSEN(zephyr_ccm))
|
||||
CCM (rw) : ORIGIN = DT_REG_ADDR(DT_CHOSEN(zephyr_ccm)), LENGTH = DT_REG_SIZE(DT_CHOSEN(zephyr_ccm))
|
||||
#endif
|
||||
#if DT_HAS_NODE(DT_CHOSEN(zephyr_dtcm))
|
||||
DTCM (rw) : ORIGIN = DT_REG_ADDR(DT_CHOSEN(zephyr_dtcm)), LENGTH = DT_REG_SIZE(DT_CHOSEN(zephyr_dtcm))
|
||||
|
|
|
@ -77,9 +77,6 @@
|
|||
MEMORY
|
||||
{
|
||||
FLASH (rx) : ORIGIN = ROM_ADDR, LENGTH = ROM_SIZE
|
||||
#ifdef DT_CCM_BASE_ADDRESS
|
||||
CCM (rw) : ORIGIN = DT_CCM_BASE_ADDRESS, LENGTH = DT_CCM_SIZE * 1K
|
||||
#endif
|
||||
SRAM (wx) : ORIGIN = RAM_ADDR, LENGTH = RAM_SIZE
|
||||
/* Used by and documented in include/linker/intlist.ld */
|
||||
IDT_LIST (wx) : ORIGIN = (RAM_ADDR + RAM_SIZE), LENGTH = 2K
|
||||
|
|
|
@ -215,7 +215,7 @@ extern char __gcov_bss_size[];
|
|||
/* end address of image, used by newlib for the heap */
|
||||
extern char _end[];
|
||||
|
||||
#ifdef DT_CCM_BASE_ADDRESS
|
||||
#if DT_HAS_NODE(DT_CHOSEN(zephyr_ccm))
|
||||
extern char __ccm_data_rom_start[];
|
||||
extern char __ccm_start[];
|
||||
extern char __ccm_data_start[];
|
||||
|
@ -225,7 +225,7 @@ extern char __ccm_bss_end[];
|
|||
extern char __ccm_noinit_start[];
|
||||
extern char __ccm_noinit_end[];
|
||||
extern char __ccm_end[];
|
||||
#endif /* DT_CCM_BASE_ADDRESS */
|
||||
#endif
|
||||
|
||||
#if DT_HAS_NODE(DT_CHOSEN(zephyr_dtcm))
|
||||
extern char __dtcm_data_start[];
|
||||
|
|
|
@ -106,7 +106,7 @@ extern void idle(void *unused1, void *unused2, void *unused3);
|
|||
void z_bss_zero(void)
|
||||
{
|
||||
(void)memset(__bss_start, 0, __bss_end - __bss_start);
|
||||
#ifdef DT_CCM_BASE_ADDRESS
|
||||
#if DT_HAS_NODE(DT_CHOSEN(zephyr_ccm))
|
||||
(void)memset(&__ccm_bss_start, 0,
|
||||
((u32_t) &__ccm_bss_end - (u32_t) &__ccm_bss_start));
|
||||
#endif
|
||||
|
@ -147,7 +147,7 @@ void z_data_copy(void)
|
|||
(void)memcpy(&_ramfunc_ram_start, &_ramfunc_rom_start,
|
||||
(uintptr_t) &_ramfunc_ram_size);
|
||||
#endif /* CONFIG_ARCH_HAS_RAMFUNC_SUPPORT */
|
||||
#ifdef DT_CCM_BASE_ADDRESS
|
||||
#if DT_HAS_NODE(DT_CHOSEN(zephyr_ccm))
|
||||
(void)memcpy(&__ccm_data_start, &__ccm_data_rom_start,
|
||||
__ccm_data_end - __ccm_data_start);
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue