Skip to content

Commit e11b769

Browse files
arch: add dependencie for CONFIG_SRAM_VECTOR_TABLE
Move SRAM_VECTOR_TABLE symbol from general Kconfig to Arch Kconfig because it depends on the architecture possibility to relocate the vector table. Signed-off-by: Martin Hoff <martin.hoff@silabs.com>
1 parent e02bd58 commit e11b769

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed

Kconfig.zephyr

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -215,12 +215,6 @@ config LINKER_SORT_BY_ALIGNMENT
215215
in decreasing size of symbols. This helps to minimize
216216
padding between symbols.
217217

218-
config SRAM_VECTOR_TABLE
219-
bool "Place the vector table in SRAM instead of flash"
220-
help
221-
The option specifies that the vector table should be placed at the
222-
start of SRAM instead of the start of flash.
223-
224218
config HAS_SRAM_OFFSET
225219
bool
226220
help

arch/Kconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -573,6 +573,14 @@ config IRQ_OFFLOAD
573573
run in interrupt context. Only useful for test cases that need
574574
to validate the correctness of kernel objects in IRQ context.
575575

576+
config SRAM_VECTOR_TABLE
577+
bool "Place the vector table in SRAM instead of flash"
578+
depends on ARCH_HAS_VECTOR_TABLE_RELOCATION
579+
depends on XIP
580+
help
581+
The option specifies that the vector table will be placed at the
582+
start of SRAM instead of the start of the flash when XIP is enabled.
583+
576584
config IRQ_OFFLOAD_NESTED
577585
bool "irq_offload() supports nested IRQs"
578586
depends on IRQ_OFFLOAD
@@ -671,6 +679,9 @@ config ARCH_HAS_NOCACHE_MEMORY_SUPPORT
671679
config ARCH_HAS_RAMFUNC_SUPPORT
672680
bool
673681

682+
config ARCH_HAS_VECTOR_TABLE_RELOCATION
683+
bool
684+
674685
config ARCH_HAS_NESTED_EXCEPTION_DETECTION
675686
bool
676687

arch/arm/core/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ config CPU_CORTEX_M
1616
select ARCH_HAS_USERSPACE if ARM_MPU
1717
select ARCH_HAS_NOCACHE_MEMORY_SUPPORT if ARM_MPU && CPU_HAS_ARM_MPU && CPU_HAS_DCACHE
1818
select ARCH_HAS_RAMFUNC_SUPPORT
19+
select ARCH_HAS_VECTOR_TABLE_RELOCATION if CPU_CORTEX_M_HAS_VTOR
1920
select ARCH_HAS_NESTED_EXCEPTION_DETECTION
2021
select SWAP_NONATOMIC
2122
select ARCH_HAS_EXTRA_EXCEPTION_INFO

0 commit comments

Comments
 (0)