arch: riscv: introduce CONFIG_RISCV_GP_PURPOSE
choice
Introduce `CONFIG_RISCV_GP_PURPOSE` choice to make sure that only one of `CONFIG_RISCV_GP` or `CONFIG_RISCV_CURRENT_VIA_GP` can be enabled, instead of relying of dependencies. To do that, introduce a new `CONFIG_RISCV_SOC_HAS_GP_RELATIVE_ADDRESSING` that can be selected by SoC when it implemented global pointer (GP) initialization for relative addressing in its linker. `CONFIG_RISCV_GP` will be the default choice when `CONFIG_RISCV_SOC_HAS_GP_RELATIVE_ADDRESSING=y` Signed-off-by: Yong Cong Sin <ycsin@meta.com> Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
This commit is contained in:
parent
033804e266
commit
e6dd68ec89
37 changed files with 33 additions and 56 deletions
|
@ -16,6 +16,7 @@ config SOC_OPENTITAN
|
|||
select RISCV
|
||||
select RISCV_PRIVILEGED
|
||||
select RISCV_HAS_PLIC
|
||||
select RISCV_SOC_HAS_GP_RELATIVE_ADDRESSING
|
||||
# OpenTitan Ibex core mtvec mode is read-only / forced to vectored mode.
|
||||
select RISCV_VECTORED_MODE
|
||||
select GEN_IRQ_VECTOR_TABLE
|
||||
|
|
|
@ -9,9 +9,6 @@ config SYS_CLOCK_HW_CYCLES_PER_SEC
|
|||
config RISCV_SOC_INTERRUPT_INIT
|
||||
default y
|
||||
|
||||
config RISCV_GP
|
||||
default y
|
||||
|
||||
config 2ND_LVL_ISR_TBL_OFFSET
|
||||
default 32
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue