2016-10-16 23:47:07 +08:00
|
|
|
#
|
|
|
|
# For a description of the syntax of this configuration file,
|
|
|
|
# see the file kconfig-language.txt in the NuttX tools repository.
|
|
|
|
#
|
|
|
|
|
|
|
|
if ARCH_RISCV
|
|
|
|
comment "RISC-V Options"
|
|
|
|
|
|
|
|
choice
|
|
|
|
prompt "RISC-V chip selection"
|
2021-03-11 11:06:42 +08:00
|
|
|
default ARCH_CHIP_RISCV_CUSTOM
|
2016-10-16 23:47:07 +08:00
|
|
|
|
2019-11-29 04:37:24 +08:00
|
|
|
config ARCH_CHIP_FE310
|
|
|
|
bool "SiFive FE310"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
2022-04-11 18:42:24 +08:00
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
2019-11-29 04:37:24 +08:00
|
|
|
---help---
|
|
|
|
SiFive FE310 processor (E31 RISC-V Core with MAC extensions).
|
|
|
|
|
2019-12-31 23:06:20 +08:00
|
|
|
config ARCH_CHIP_K210
|
|
|
|
bool "Kendryte K210"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV64
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
2022-04-22 12:21:13 +08:00
|
|
|
select ARCH_HAVE_FPU if !K210_WITH_QEMU
|
|
|
|
select ARCH_HAVE_DPFPU if !K210_WITH_QEMU
|
2020-02-14 15:10:50 +08:00
|
|
|
select ARCH_HAVE_MPU
|
2020-01-10 22:04:41 +08:00
|
|
|
select ARCH_HAVE_TESTSET
|
|
|
|
select ARCH_HAVE_MULTICPU
|
2022-04-11 09:47:53 +08:00
|
|
|
select ARCH_HAVE_MISALIGN_EXCEPTION
|
2022-04-11 18:42:24 +08:00
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
2019-12-31 23:06:20 +08:00
|
|
|
---help---
|
|
|
|
Kendryte K210 processor (RISC-V 64bit core with GC extensions)
|
|
|
|
|
2020-03-21 14:01:56 +08:00
|
|
|
config ARCH_CHIP_LITEX
|
|
|
|
bool "Enjoy Digital LITEX VEXRISCV"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
2022-03-24 11:06:51 +08:00
|
|
|
select ARCH_DCACHE
|
2023-08-16 08:05:27 +08:00
|
|
|
select ARCH_HAVE_TICKLESS
|
2023-08-25 10:00:35 +08:00
|
|
|
select ARCH_HAVE_RESET
|
2024-03-19 06:46:56 +08:00
|
|
|
select LIBC_FDT
|
|
|
|
select DEVICE_TREE
|
2020-03-21 14:01:56 +08:00
|
|
|
---help---
|
|
|
|
Enjoy Digital LITEX VEXRISCV softcore processor (RV32IMA).
|
|
|
|
|
2020-12-17 19:04:46 +08:00
|
|
|
config ARCH_CHIP_BL602
|
|
|
|
bool "BouffaloLab BL602"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
2022-01-15 09:32:45 +08:00
|
|
|
select ARCH_HAVE_FPU
|
2021-01-01 04:22:53 +08:00
|
|
|
select ARCH_HAVE_RESET
|
2022-04-11 09:47:53 +08:00
|
|
|
select ARCH_HAVE_MISALIGN_EXCEPTION
|
2022-04-11 18:42:24 +08:00
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
2020-12-17 19:04:46 +08:00
|
|
|
---help---
|
|
|
|
BouffaloLab BL602(rv32imfc)
|
|
|
|
|
2021-01-21 20:13:10 +08:00
|
|
|
config ARCH_CHIP_ESP32C3
|
|
|
|
bool "Espressif ESP32-C3"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_C
|
2021-01-21 20:13:10 +08:00
|
|
|
select ARCH_VECNOTIRQ
|
2022-04-12 08:09:25 +08:00
|
|
|
select ARCH_HAVE_MPU
|
2021-02-19 18:55:39 +08:00
|
|
|
select ARCH_HAVE_RESET
|
2021-11-13 21:06:26 +08:00
|
|
|
select LIBC_ARCH_MEMCPY
|
|
|
|
select LIBC_ARCH_MEMCHR
|
2021-12-30 19:50:22 +08:00
|
|
|
select LIBC_ARCH_MEMCMP
|
|
|
|
select LIBC_ARCH_MEMMOVE
|
|
|
|
select LIBC_ARCH_MEMSET
|
2021-11-13 21:06:26 +08:00
|
|
|
select LIBC_ARCH_STRCHR
|
|
|
|
select LIBC_ARCH_STRCMP
|
2021-12-30 19:50:22 +08:00
|
|
|
select LIBC_ARCH_STRCPY
|
2021-11-13 21:06:26 +08:00
|
|
|
select LIBC_ARCH_STRLCPY
|
|
|
|
select LIBC_ARCH_STRNCPY
|
|
|
|
select LIBC_ARCH_STRLEN
|
|
|
|
select LIBC_ARCH_STRNLEN
|
2021-06-18 07:47:45 +08:00
|
|
|
select ARCH_HAVE_TEXT_HEAP
|
2021-09-24 20:20:42 +08:00
|
|
|
select ARCH_HAVE_BOOTLOADER
|
2023-07-21 15:34:55 +08:00
|
|
|
select ARCH_HAVE_PERF_EVENTS
|
2024-06-24 17:41:46 +08:00
|
|
|
select ARCH_HAVE_DEBUG
|
2024-11-12 20:10:25 +08:00
|
|
|
select ARCH_HAVE_RAMFUNCS
|
2021-01-21 20:13:10 +08:00
|
|
|
---help---
|
|
|
|
Espressif ESP32-C3 (RV32IMC).
|
|
|
|
|
2024-01-08 16:26:14 +08:00
|
|
|
config ARCH_CHIP_ESP32C3_GENERIC
|
|
|
|
bool "ESP32-C3"
|
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_VECNOTIRQ
|
|
|
|
select ARCH_HAVE_BOOTLOADER if !ESPRESSIF_SIMPLE_BOOT
|
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_HAVE_RESET
|
|
|
|
select ARCH_HAVE_RNG
|
|
|
|
select ARCH_HAVE_TICKLESS
|
|
|
|
select LIBC_ARCH_MEMCPY
|
|
|
|
select LIBC_ARCH_MEMCHR
|
|
|
|
select LIBC_ARCH_MEMCMP
|
|
|
|
select LIBC_ARCH_MEMMOVE
|
|
|
|
select LIBC_ARCH_MEMSET
|
|
|
|
select LIBC_ARCH_STRCHR
|
|
|
|
select LIBC_ARCH_STRCMP
|
|
|
|
select LIBC_ARCH_STRCPY
|
|
|
|
select LIBC_ARCH_STRLCPY
|
|
|
|
select LIBC_ARCH_STRNCPY
|
|
|
|
select LIBC_ARCH_STRLEN
|
|
|
|
select LIBC_ARCH_STRNLEN
|
|
|
|
select ESPRESSIF_SOC_RTC_MEM_SUPPORTED
|
|
|
|
select ARCH_CHIP_ESPRESSIF
|
2024-06-24 17:41:46 +08:00
|
|
|
select ARCH_HAVE_DEBUG
|
2024-11-12 20:10:25 +08:00
|
|
|
select ARCH_HAVE_RAMFUNCS
|
2024-01-08 16:26:14 +08:00
|
|
|
---help---
|
|
|
|
ESP32-C3 chip with a single RISC-V IMC core, no embedded Flash memory
|
|
|
|
|
|
|
|
config ARCH_CHIP_ESP32C6
|
|
|
|
bool "ESP32-C6"
|
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_VECNOTIRQ
|
2024-02-05 18:36:04 +08:00
|
|
|
select ARCH_HAVE_BOOTLOADER if !ESPRESSIF_SIMPLE_BOOT
|
2024-01-08 16:26:14 +08:00
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_HAVE_RESET
|
|
|
|
select ARCH_HAVE_RNG
|
|
|
|
select ARCH_HAVE_TICKLESS
|
|
|
|
select LIBC_ARCH_MEMCPY
|
|
|
|
select LIBC_ARCH_MEMCHR
|
|
|
|
select LIBC_ARCH_MEMCMP
|
|
|
|
select LIBC_ARCH_MEMMOVE
|
|
|
|
select LIBC_ARCH_MEMSET
|
|
|
|
select LIBC_ARCH_STRCHR
|
|
|
|
select LIBC_ARCH_STRCMP
|
|
|
|
select LIBC_ARCH_STRCPY
|
|
|
|
select LIBC_ARCH_STRLCPY
|
|
|
|
select LIBC_ARCH_STRNCPY
|
|
|
|
select LIBC_ARCH_STRLEN
|
|
|
|
select LIBC_ARCH_STRNLEN
|
|
|
|
select ESPRESSIF_SOC_RTC_MEM_SUPPORTED
|
|
|
|
select ARCH_CHIP_ESPRESSIF
|
|
|
|
---help---
|
|
|
|
Espressif ESP32-C6 (RV32IMAC).
|
|
|
|
|
|
|
|
config ARCH_CHIP_ESP32H2
|
|
|
|
bool "ESP32-H2"
|
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_VECNOTIRQ
|
2024-02-10 01:05:26 +08:00
|
|
|
select ARCH_HAVE_BOOTLOADER if !ESPRESSIF_SIMPLE_BOOT
|
2024-01-08 16:26:14 +08:00
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_HAVE_RESET
|
|
|
|
select ARCH_HAVE_RNG
|
|
|
|
select ARCH_HAVE_TICKLESS
|
|
|
|
select LIBC_ARCH_MEMCPY
|
|
|
|
select LIBC_ARCH_MEMCHR
|
|
|
|
select LIBC_ARCH_MEMCMP
|
|
|
|
select LIBC_ARCH_MEMMOVE
|
|
|
|
select LIBC_ARCH_MEMSET
|
|
|
|
select LIBC_ARCH_STRCHR
|
|
|
|
select LIBC_ARCH_STRCMP
|
|
|
|
select LIBC_ARCH_STRCPY
|
|
|
|
select LIBC_ARCH_STRLCPY
|
|
|
|
select LIBC_ARCH_STRNCPY
|
|
|
|
select LIBC_ARCH_STRLEN
|
|
|
|
select LIBC_ARCH_STRNLEN
|
|
|
|
select ESPRESSIF_ESPTOOLPY_NO_STUB
|
|
|
|
select ESPRESSIF_SOC_RTC_MEM_SUPPORTED
|
|
|
|
select ARCH_CHIP_ESPRESSIF
|
2023-01-24 21:31:15 +08:00
|
|
|
---help---
|
2024-01-08 16:26:14 +08:00
|
|
|
Espressif ESP32-H2 (RV32IMC).
|
2023-01-24 21:31:15 +08:00
|
|
|
|
2021-03-08 23:19:29 +08:00
|
|
|
config ARCH_CHIP_C906
|
|
|
|
bool "THEAD C906"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV64
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
2022-01-15 09:32:45 +08:00
|
|
|
select ARCH_HAVE_FPU
|
|
|
|
select ARCH_HAVE_DPFPU
|
2021-03-16 10:06:06 +08:00
|
|
|
select ARCH_HAVE_MPU
|
2022-04-11 18:42:24 +08:00
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
2021-03-08 23:19:29 +08:00
|
|
|
---help---
|
|
|
|
THEAD C906 processor (RISC-V 64bit core with GCVX extensions).
|
|
|
|
|
2021-05-04 18:56:52 +08:00
|
|
|
config ARCH_CHIP_MPFS
|
2021-12-14 15:52:49 +08:00
|
|
|
bool "MicroChip Polarfire (MPFS)"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV64
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
2022-01-15 09:32:45 +08:00
|
|
|
select ARCH_HAVE_FPU
|
|
|
|
select ARCH_HAVE_DPFPU
|
2024-10-11 18:21:59 +08:00
|
|
|
select ARCH_HAVE_MULTICPU
|
2021-12-14 15:52:49 +08:00
|
|
|
select ARCH_HAVE_MPU
|
2022-01-19 16:14:28 +08:00
|
|
|
select ARCH_MMU_TYPE_SV39
|
2022-03-11 19:35:39 +08:00
|
|
|
select ARCH_HAVE_ADDRENV
|
|
|
|
select ARCH_NEED_ADDRENV_MAPPING
|
2021-12-14 15:52:49 +08:00
|
|
|
select ARCH_HAVE_RESET
|
|
|
|
select ARCH_HAVE_SPI_CS_CONTROL
|
|
|
|
select ARCH_HAVE_PWM_MULTICHAN
|
2022-03-17 17:20:42 +08:00
|
|
|
select ARCH_HAVE_S_MODE
|
2022-04-11 18:42:24 +08:00
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
2021-12-14 15:52:49 +08:00
|
|
|
---help---
|
2021-05-04 18:56:52 +08:00
|
|
|
MicroChip Polarfire processor (RISC-V 64bit core with GCVX extensions).
|
|
|
|
|
2021-06-04 15:30:49 +08:00
|
|
|
config ARCH_CHIP_RV32M1
|
|
|
|
bool "NXP RV32M1"
|
2021-12-27 00:18:22 +08:00
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_C
|
2021-06-04 15:30:49 +08:00
|
|
|
---help---
|
|
|
|
NXP RV32M1 processor (RISC-V Core with PULP extensions).
|
|
|
|
|
2022-01-14 17:18:29 +08:00
|
|
|
config ARCH_CHIP_QEMU_RV
|
|
|
|
bool "QEMU RV"
|
2023-06-20 18:39:52 +08:00
|
|
|
select ARCH_HAVE_FPU
|
|
|
|
select ARCH_HAVE_DPFPU
|
2022-02-17 21:23:41 +08:00
|
|
|
select ARCH_HAVE_MULTICPU
|
2022-05-09 10:00:56 +08:00
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_MMU_TYPE_SV39 if ARCH_CHIP_QEMU_RV64
|
2023-03-27 07:01:47 +08:00
|
|
|
select ARCH_MMU_TYPE_SV32 if ARCH_CHIP_QEMU_RV32
|
2024-07-10 18:21:58 +08:00
|
|
|
select NUTTSBI_LATE_INIT if NUTTSBI
|
2022-05-09 10:00:56 +08:00
|
|
|
select ARCH_HAVE_ADDRENV
|
|
|
|
select ARCH_NEED_ADDRENV_MAPPING
|
|
|
|
select ARCH_HAVE_S_MODE
|
risc-v/rv-virt: use fully linked apps for kernel build
Fully linked apps take less storage and are efficient to load. This
is to enable them for rv-vrit configurations in KERNEL build.
Changes:
- arch/risc-v/Kconfig select BINFMT_ELF_EXECUTABLE for QEMU-RV
- boards/risc-v/qemu-rv/rv-virt/configs
- knsh32/defconfig enable ELF_EXECUTABLE, LIBM, OSTEST
- knsh64/defconfig enable ELF_EXECUTABLE, LIBM, OSTEST
- ksmp64/defconfig enable ELF_EXECUTABLE, LIBM, OSTEST
- knetnsh64/defconfig enable ELF_EXECUTABLE, LIBM, OSTEST
- knetnsh64_smp/defconfig enable ELF_EXECUTABLE, LIBM, OSTEST
Additions:
- boards/risc-v/qemu-rv/rv-virt/scripts/
- gnu-elf.ld apps linker script
The ARCH_TEXT_VBASE of knsh32 is set to same as that of 64bit to reuse
the apps linker script.
Signed-off-by: Yanfeng Liu <yfliu2008@qq.com>
2024-01-11 11:37:40 +08:00
|
|
|
select ARCH_HAVE_ELF_EXECUTABLE
|
2022-04-11 18:42:24 +08:00
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
2024-06-24 17:41:46 +08:00
|
|
|
select ARCH_HAVE_DEBUG
|
2021-12-05 21:41:44 +08:00
|
|
|
---help---
|
2022-02-17 21:23:41 +08:00
|
|
|
QEMU Generic RV32/RV64 processor
|
2021-12-05 21:41:44 +08:00
|
|
|
|
2024-02-18 15:13:03 +08:00
|
|
|
config ARCH_CHIP_HPM6000
|
|
|
|
bool "Hpmicro HPM6000"
|
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
|
|
|
---help---
|
|
|
|
Hpmicro HPM6000 processor (D45 RISC-V Core with MAC extensions).
|
|
|
|
|
2023-02-08 10:49:31 +08:00
|
|
|
config ARCH_CHIP_HPM6750
|
|
|
|
bool "Hpmicro HPM6750"
|
|
|
|
select ARCH_RV32
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
|
|
|
---help---
|
|
|
|
Hpmicro HPM6750 processor (D45 RISC-V Core with MAC extensions).
|
|
|
|
|
2023-08-04 07:31:14 +08:00
|
|
|
config ARCH_CHIP_JH7110
|
|
|
|
bool "StarFive JH7110"
|
|
|
|
select ARCH_RV64
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_HAVE_FPU
|
|
|
|
select ARCH_HAVE_DPFPU
|
|
|
|
select ARCH_HAVE_MULTICPU
|
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_MMU_TYPE_SV39
|
|
|
|
select ARCH_HAVE_ADDRENV
|
|
|
|
select ARCH_NEED_ADDRENV_MAPPING
|
|
|
|
select ARCH_HAVE_S_MODE
|
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
|
|
|
---help---
|
|
|
|
StarFive JH7110 SoC.
|
|
|
|
|
2023-12-12 09:00:08 +08:00
|
|
|
config ARCH_CHIP_BL808
|
|
|
|
bool "Bouffalo Lab BL808"
|
|
|
|
select ARCH_RV64
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_HAVE_FPU
|
|
|
|
select ARCH_HAVE_DPFPU
|
|
|
|
select ARCH_HAVE_MULTICPU
|
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_MMU_TYPE_SV39
|
2024-08-28 09:30:23 +08:00
|
|
|
select ARCH_MMU_EXT_THEAD
|
2023-12-12 09:00:08 +08:00
|
|
|
select ARCH_HAVE_ADDRENV
|
|
|
|
select ARCH_NEED_ADDRENV_MAPPING
|
|
|
|
select ARCH_HAVE_S_MODE
|
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
|
|
|
---help---
|
|
|
|
Bouffalo Lab BL808 SoC.
|
|
|
|
|
2023-12-13 10:59:21 +08:00
|
|
|
config ARCH_CHIP_K230
|
|
|
|
bool "Kendryte K230"
|
|
|
|
select ARCH_RV64
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_HAVE_FPU
|
|
|
|
select ARCH_HAVE_DPFPU
|
|
|
|
select ARCH_HAVE_MISALIGN_EXCEPTION
|
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_HAVE_ADDRENV
|
2024-03-13 11:25:58 +08:00
|
|
|
select ARCH_HAVE_RESET
|
2023-12-13 10:59:21 +08:00
|
|
|
select ARCH_HAVE_S_MODE
|
2024-01-09 20:29:38 +08:00
|
|
|
select ARCH_HAVE_ELF_EXECUTABLE
|
2024-03-13 11:25:58 +08:00
|
|
|
select ARCH_MMU_TYPE_SV39
|
|
|
|
select ARCH_NEED_ADDRENV_MAPPING
|
2024-02-08 14:21:08 +08:00
|
|
|
select NUTTSBI_LATE_INIT if NUTTSBI
|
2023-12-13 10:59:21 +08:00
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
|
|
|
---help---
|
|
|
|
Kendryte K230 SoC (RV64GCV and RV64GCVX C908 cores).
|
|
|
|
|
2024-06-16 19:39:17 +08:00
|
|
|
config ARCH_CHIP_SG2000
|
|
|
|
bool "SOPHGO SG2000"
|
|
|
|
select ARCH_RV64
|
|
|
|
select ARCH_RV_ISA_M
|
|
|
|
select ARCH_RV_ISA_A
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_HAVE_FPU
|
|
|
|
select ARCH_HAVE_DPFPU
|
|
|
|
select ARCH_HAVE_MULTICPU
|
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_MMU_TYPE_SV39
|
risc-v/mmu: Configure T-Head MMU to cache User Text, Data and Heap
This PR configures the T-Head MMU to cache the the User Text, Data and Heap. We enable the MMU Flags for Shareable, Bufferable and Cacheable, as explained in this article: https://lupyuen.github.io/articles/plic3#appendix-mmu-caching-for-t-head-c906
This PR fixes the Slow Memory Access for NuttX Apps on BL808 and SG2000 SoCs: https://github.com/apache/nuttx/issues/12696. With this fix, SG2000 NuttX CoreMark jumps from 21 to 2,423. (Close to SG2000 Debian CoreMark)
We introduce a Kconfig Option: `ARCH_MMU_EXT_THEAD` ("System Type > Enable T-Head MMU extension support"). Enabling this Kconfig Option will configure the T-Head MMU to cache the User Text, Data and Heap.
This PR enables the MMU cache for only SG2000 SoC (Milk-V Duo S SBC). The next PR will apply the same settings to BL808 SoC (Pine64 Ox64 SBC).
Modified Files:
`arch/risc-v/Kconfig`: Added Kconfig Option `ARCH_MMU_EXT_THEAD` that will configure the T-Head MMU. Enabled `ARCH_MMU_EXT_THEAD` for SG2000 SoC.
`arch/risc-v/src/common/riscv_mmu.h`: Set the T-Head MMU Flags (Shareable, Bufferable and Cacheable) for User Text, Data and Heap, if `ARCH_MMU_EXT_THEAD` is enabled
`arch/risc-v/src/common/riscv_addrenv.c`: Extended the MMU Flags from 32 bits to 64 bits, to accommodate the T-Head MMU Flags
`arch/risc-v/src/common/riscv_exception.c`: Extended the MMU Flags from 32 bits to 64 bit, to accommodate the T-Head MMU Flags. This code is enabled only for MMU Paging (`CONFIG_PAGING`).
2024-08-26 15:08:40 +08:00
|
|
|
select ARCH_MMU_EXT_THEAD
|
2024-06-16 19:39:17 +08:00
|
|
|
select ARCH_HAVE_ADDRENV
|
|
|
|
select ARCH_NEED_ADDRENV_MAPPING
|
|
|
|
select ARCH_HAVE_S_MODE
|
|
|
|
select ONESHOT
|
|
|
|
select ALARM_ARCH
|
|
|
|
---help---
|
|
|
|
SOPHGO SG2000 SoC.
|
|
|
|
|
2020-10-15 11:29:59 +08:00
|
|
|
config ARCH_CHIP_RISCV_CUSTOM
|
|
|
|
bool "Custom RISC-V chip"
|
|
|
|
select ARCH_CHIP_CUSTOM
|
|
|
|
---help---
|
|
|
|
Select this option if there is no directory for the chip under arch/risc-v/src/.
|
|
|
|
|
2024-04-08 22:21:13 +08:00
|
|
|
endchoice # RISC-V chip selection
|
2016-10-16 23:47:07 +08:00
|
|
|
|
2021-12-27 00:18:22 +08:00
|
|
|
config ARCH_RV32
|
2016-10-16 23:47:07 +08:00
|
|
|
bool
|
|
|
|
default n
|
|
|
|
|
2021-12-27 00:18:22 +08:00
|
|
|
config ARCH_RV64
|
2016-10-16 23:47:07 +08:00
|
|
|
bool
|
|
|
|
default n
|
2024-06-08 08:45:28 +08:00
|
|
|
select LIBC_ARCH_ELF_64BIT if LIBC_ARCH_ELF && !ARCH_RV64ILP32
|
|
|
|
|
|
|
|
config ARCH_RV64ILP32
|
|
|
|
bool
|
|
|
|
depends on ARCH_RV64
|
|
|
|
default n
|
2016-10-16 23:47:07 +08:00
|
|
|
|
2021-12-27 00:18:22 +08:00
|
|
|
config ARCH_RV_ISA_M
|
|
|
|
bool
|
|
|
|
default n
|
|
|
|
|
|
|
|
config ARCH_RV_ISA_A
|
|
|
|
bool
|
|
|
|
default n
|
2021-12-29 18:39:41 +08:00
|
|
|
select ARCH_HAVE_TESTSET
|
2021-12-27 00:18:22 +08:00
|
|
|
|
|
|
|
config ARCH_RV_ISA_C
|
|
|
|
bool
|
|
|
|
default n
|
|
|
|
|
2024-01-16 08:33:53 +08:00
|
|
|
config ARCH_RV_ISA_V
|
|
|
|
bool
|
|
|
|
default n
|
|
|
|
depends on ARCH_FPU
|
|
|
|
|
2024-04-22 10:10:25 +08:00
|
|
|
if ARCH_RV_ISA_V
|
|
|
|
|
|
|
|
config ARCH_RV_VECTOR_BYTE_LENGTH
|
|
|
|
int "Vector Register Length in bytes"
|
|
|
|
default 32
|
|
|
|
---help---
|
|
|
|
Predefined vector register length. If CSR vlenb is greater than the
|
|
|
|
current reserved value, appropriate memory will be allocated to
|
|
|
|
save/restore the vector registers.
|
|
|
|
The XLEN-bit-wide read-only CSR vlenb holds the value VLEN/8, i.e.,
|
|
|
|
the vector register length in bytes. The value in vlenb is a
|
|
|
|
design-time constant in any implementation. Without this CSR, several
|
|
|
|
instructions are needed to calculate VLEN in bytes. The code has to
|
|
|
|
disturb current vl and vtype settings which require them to be saved and restored.
|
|
|
|
|
|
|
|
endif
|
|
|
|
|
2024-09-17 20:39:40 +08:00
|
|
|
config ARCH_RV_MACHINE_ISA_1_13
|
|
|
|
bool "Machine ISA Version 1.13 or later"
|
|
|
|
default n
|
|
|
|
---help---
|
|
|
|
Indicates support for Machine ISA Version 1.13 or later.
|
|
|
|
This version defined hardware error and software check exception codes,
|
|
|
|
which extend the range of exception codes from 0 ~ 15 to 0 ~ 19.
|
|
|
|
|
2024-01-16 08:57:01 +08:00
|
|
|
config ARCH_RV_ISA_ZICSR_ZIFENCEI
|
2024-10-11 23:48:31 +08:00
|
|
|
bool "Enable Zicsr and Zifencei extensions (GCC >= 12.1.0.)"
|
2024-01-16 08:57:01 +08:00
|
|
|
default y
|
|
|
|
---help---
|
|
|
|
https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=aed44286efa8ae8717a77d94b51ac3614e2ca6dc
|
|
|
|
https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=98416dbb0a62579d4a7a4a76bab51b5b52fec2cd
|
|
|
|
GCC-12.1.0 bumped the default ISA spec to the newer 20191213 version,
|
|
|
|
which moves some instructions from the I extension to the Zicsr and
|
|
|
|
Zifencei extensions. This requires explicitly specifying Zicsr and
|
|
|
|
Zifencei when GCC >= 12.1.0. To make life easier, and avoid forcing
|
|
|
|
toolchains that default to a newer ISA spec to version 2.2. For
|
|
|
|
clang < 17 or GCC < 11.3.0, for which this is not possible or need
|
|
|
|
special treatment.
|
|
|
|
|
2024-04-19 09:20:21 +08:00
|
|
|
config ARCH_RV_EXPERIMENTAL_EXTENSIONS
|
|
|
|
string "LLVM RISC-V Experimental Extensions"
|
|
|
|
default ""
|
|
|
|
depends on RISCV_TOOLCHAIN_CLANG
|
|
|
|
---help---
|
|
|
|
This option allows the platform to enable experimental extensions,
|
|
|
|
LLVM supports (to various degrees) a number of experimental extensions.
|
|
|
|
All experimental extensions have experimental- as a prefix. There is
|
|
|
|
explicitly no compatibility promised between versions of the toolchain,
|
|
|
|
and regular users are strongly advised not to make use of experimental
|
|
|
|
extensions before they reach ratification.
|
|
|
|
|
2024-01-16 09:45:35 +08:00
|
|
|
config ARCH_RV_ISA_VENDOR_EXTENSIONS
|
|
|
|
string "Vendor Custom RISC-V Instruction Set Architecture Extensions"
|
|
|
|
default ""
|
|
|
|
---help---
|
|
|
|
This option allows the platform to enable some vendor-customized ISA extensions,
|
|
|
|
E.g OpenHW, SiFive, T-Head.
|
|
|
|
|
|
|
|
SiFive Intelligence Extensions:
|
|
|
|
SiFive Vector Coprocessor Interface(VCIX): xsfvcp
|
|
|
|
SiFive FP32-to-int8 Ranged Clip Instructions: Xsfvfnrclipxfqf
|
|
|
|
SiFive Matrix Multiply Accumulate Instructions: Xsfvfwmaccqqq
|
|
|
|
SiFive Int8 Matrix Multiplication Instructions: XSFvqmaccqoq
|
|
|
|
Command Line:
|
|
|
|
xsfvcp0p1_xsfvfnrclipxfqf0p1_xsfvfwmaccqqq0p1_xsfvqmaccqoq0p1
|
|
|
|
|
2023-12-13 10:59:21 +08:00
|
|
|
config ARCH_RV_MMIO_BITS
|
|
|
|
int
|
|
|
|
# special cases
|
2024-04-08 22:21:13 +08:00
|
|
|
default 32 if ARCH_CHIP_K230
|
2023-12-13 10:59:21 +08:00
|
|
|
# general fallbacks
|
2024-04-08 22:21:13 +08:00
|
|
|
default 32 if ARCH_RV32
|
|
|
|
default 64 if ARCH_RV64
|
2023-12-13 10:59:21 +08:00
|
|
|
|
2024-12-31 19:05:48 +08:00
|
|
|
config ARCH_RV_CPUID_MAP
|
|
|
|
bool "Enable CPUID mapping"
|
|
|
|
default n
|
|
|
|
---help---
|
|
|
|
Enable CPUID mapping for systems where the hardware CPU IDs
|
|
|
|
need to be mapped to logical CPU IDs. This is useful for
|
|
|
|
systems with non-contiguous or non-linear CPU numbering.
|
|
|
|
|
2024-07-29 16:01:54 +08:00
|
|
|
config ARCH_RV_HARTID_BASE
|
|
|
|
int "Base hartid of this cluster"
|
|
|
|
default 0
|
|
|
|
---help---
|
2024-12-31 19:05:48 +08:00
|
|
|
This setting is used in multi-cluster RISC-V systems where each hardware
|
|
|
|
thread (hart) has a globally unique mhartid value.
|
|
|
|
|
|
|
|
Purpose:
|
|
|
|
- Maps global hardware thread IDs (mhartid) to cluster-local IDs
|
|
|
|
- Enables NuttX to work with cluster-local hart IDs while maintaining
|
|
|
|
global uniqueness across the system
|
|
|
|
|
|
|
|
Example:
|
|
|
|
In a system with:
|
|
|
|
- Cluster A: harts 100-103
|
|
|
|
- Cluster B: harts 200-203
|
|
|
|
- Cluster C: harts 300-303
|
|
|
|
|
|
|
|
If this is Cluster B's configuration, set ARCH_RV_HARTID_BASE=200.
|
|
|
|
NuttX will then map:
|
|
|
|
- Global hart 200 -> Local hart 0
|
|
|
|
- Global hart 201 -> Local hart 1
|
|
|
|
- Global hart 202 -> Local hart 2
|
|
|
|
- Global hart 203 -> Local hart 3
|
|
|
|
|
|
|
|
Key Points:
|
|
|
|
1. SMP_NCPUS defines the number of harts in this cluster
|
|
|
|
2. Global hart IDs within a cluster must be consecutive
|
|
|
|
3. Some chips like K230 don't use global mhartid numbering
|
|
|
|
4. The base value should match the starting mhartid of this cluster
|
|
|
|
5. Local hart IDs always start from 0 within each cluster
|
|
|
|
|
|
|
|
Special Cases:
|
|
|
|
- For chips like K230 that don't use global mhartid numbering,
|
|
|
|
this value should typically be set to 0
|
|
|
|
- In single-cluster systems, this can usually remain at default (0)
|
2024-07-29 16:01:54 +08:00
|
|
|
|
2016-10-16 23:47:07 +08:00
|
|
|
config ARCH_FAMILY
|
|
|
|
string
|
2024-04-08 22:21:13 +08:00
|
|
|
default "rv32" if ARCH_RV32
|
|
|
|
default "rv64" if ARCH_RV64
|
2016-10-16 23:47:07 +08:00
|
|
|
|
|
|
|
config ARCH_CHIP
|
|
|
|
string
|
2024-04-08 22:21:13 +08:00
|
|
|
default "fe310" if ARCH_CHIP_FE310
|
|
|
|
default "k210" if ARCH_CHIP_K210
|
|
|
|
default "litex" if ARCH_CHIP_LITEX
|
|
|
|
default "bl602" if ARCH_CHIP_BL602
|
|
|
|
default "esp32c3-legacy" if ARCH_CHIP_ESP32C3
|
|
|
|
default "esp32c3" if ARCH_CHIP_ESP32C3_GENERIC
|
|
|
|
default "esp32c6" if ARCH_CHIP_ESP32C6
|
|
|
|
default "esp32h2" if ARCH_CHIP_ESP32H2
|
|
|
|
default "c906" if ARCH_CHIP_C906
|
|
|
|
default "mpfs" if ARCH_CHIP_MPFS
|
|
|
|
default "rv32m1" if ARCH_CHIP_RV32M1
|
|
|
|
default "qemu-rv" if ARCH_CHIP_QEMU_RV
|
|
|
|
default "hpm6000" if ARCH_CHIP_HPM6000
|
|
|
|
default "hpm6750" if ARCH_CHIP_HPM6750
|
|
|
|
default "jh7110" if ARCH_CHIP_JH7110
|
|
|
|
default "bl808" if ARCH_CHIP_BL808
|
|
|
|
default "k230" if ARCH_CHIP_K230
|
2024-06-16 19:39:17 +08:00
|
|
|
default "sg2000" if ARCH_CHIP_SG2000
|
2021-06-04 15:30:49 +08:00
|
|
|
|
|
|
|
config ARCH_RISCV_INTXCPT_EXTENSIONS
|
|
|
|
bool "RISC-V Integer Context Extensions"
|
|
|
|
default n
|
|
|
|
---help---
|
|
|
|
RISC-V could be customized with extensions. Some Integer Context
|
|
|
|
Registers have to be saved and restored when Contexts switch.
|
|
|
|
|
|
|
|
if ARCH_RISCV_INTXCPT_EXTENSIONS
|
|
|
|
|
|
|
|
config ARCH_RISCV_INTXCPT_EXTREGS
|
|
|
|
int "Number of Extral RISC-V Integer Context Registers"
|
|
|
|
default 0
|
|
|
|
|
|
|
|
endif
|
2016-10-16 23:47:07 +08:00
|
|
|
|
2022-01-19 16:14:28 +08:00
|
|
|
config ARCH_MMU_TYPE_SV39
|
|
|
|
bool
|
|
|
|
default n
|
2024-01-16 09:10:46 +08:00
|
|
|
select ARCH_HAVE_MMU
|
2022-01-19 16:14:28 +08:00
|
|
|
|
2023-03-27 07:01:47 +08:00
|
|
|
config ARCH_MMU_TYPE_SV32
|
|
|
|
bool
|
|
|
|
default n
|
2024-01-16 09:10:46 +08:00
|
|
|
select ARCH_HAVE_MMU
|
2023-03-27 07:01:47 +08:00
|
|
|
|
risc-v/mmu: Configure T-Head MMU to cache User Text, Data and Heap
This PR configures the T-Head MMU to cache the the User Text, Data and Heap. We enable the MMU Flags for Shareable, Bufferable and Cacheable, as explained in this article: https://lupyuen.github.io/articles/plic3#appendix-mmu-caching-for-t-head-c906
This PR fixes the Slow Memory Access for NuttX Apps on BL808 and SG2000 SoCs: https://github.com/apache/nuttx/issues/12696. With this fix, SG2000 NuttX CoreMark jumps from 21 to 2,423. (Close to SG2000 Debian CoreMark)
We introduce a Kconfig Option: `ARCH_MMU_EXT_THEAD` ("System Type > Enable T-Head MMU extension support"). Enabling this Kconfig Option will configure the T-Head MMU to cache the User Text, Data and Heap.
This PR enables the MMU cache for only SG2000 SoC (Milk-V Duo S SBC). The next PR will apply the same settings to BL808 SoC (Pine64 Ox64 SBC).
Modified Files:
`arch/risc-v/Kconfig`: Added Kconfig Option `ARCH_MMU_EXT_THEAD` that will configure the T-Head MMU. Enabled `ARCH_MMU_EXT_THEAD` for SG2000 SoC.
`arch/risc-v/src/common/riscv_mmu.h`: Set the T-Head MMU Flags (Shareable, Bufferable and Cacheable) for User Text, Data and Heap, if `ARCH_MMU_EXT_THEAD` is enabled
`arch/risc-v/src/common/riscv_addrenv.c`: Extended the MMU Flags from 32 bits to 64 bits, to accommodate the T-Head MMU Flags
`arch/risc-v/src/common/riscv_exception.c`: Extended the MMU Flags from 32 bits to 64 bit, to accommodate the T-Head MMU Flags. This code is enabled only for MMU Paging (`CONFIG_PAGING`).
2024-08-26 15:08:40 +08:00
|
|
|
config ARCH_MMU_EXT_THEAD
|
|
|
|
bool "Enable T-Head MMU extension support"
|
|
|
|
default n
|
|
|
|
depends on ARCH_HAVE_MMU
|
|
|
|
---help---
|
|
|
|
Enable support for T-Head MMU extension.
|
|
|
|
|
2022-03-17 17:20:42 +08:00
|
|
|
config ARCH_HAVE_S_MODE
|
|
|
|
bool
|
|
|
|
default n
|
|
|
|
|
2022-04-11 09:47:53 +08:00
|
|
|
config ARCH_HAVE_MISALIGN_EXCEPTION
|
|
|
|
bool
|
|
|
|
default n
|
|
|
|
---help---
|
|
|
|
The chip will raise a exception while misaligned memory access.
|
|
|
|
|
|
|
|
config RISCV_MISALIGNED_HANDLER
|
|
|
|
bool "Software misaligned memory access handler"
|
|
|
|
depends on ARCH_HAVE_MISALIGN_EXCEPTION
|
|
|
|
default y
|
|
|
|
|
2024-04-23 17:27:51 +08:00
|
|
|
config RISCV_PERCPU_SCRATCH
|
|
|
|
bool "Enable Scratch-based Per-CPU storage"
|
2024-07-30 20:16:03 +08:00
|
|
|
default y if LIB_SYSCALL
|
2024-04-23 17:27:51 +08:00
|
|
|
---help---
|
|
|
|
In some special chipsets, multiple CPUs may be bundled in one hardware
|
|
|
|
thread cluster, which results in hartid and cpuindex not being exactly
|
|
|
|
the same.
|
|
|
|
This option will enable Scratch-based Per-CPU storage to distinguish
|
|
|
|
the real cpu index.
|
|
|
|
|
2022-03-17 17:20:42 +08:00
|
|
|
# Option to run NuttX in supervisor mode. This is obviously not usable in
|
|
|
|
# flat mode, is questionable in protected mode, but is mandatory in kernel
|
|
|
|
# mode.
|
|
|
|
#
|
|
|
|
# Kernel mode requires this as M-mode uses flat addressing and the kernel
|
|
|
|
# memory must be mapped in order to share memory between the kernel and
|
|
|
|
# different user tasks which reside in virtual memory.
|
2022-04-11 18:46:41 +08:00
|
|
|
#
|
|
|
|
# Note that S-mode requires a companion software (SBI)
|
|
|
|
#
|
2022-03-17 17:20:42 +08:00
|
|
|
|
|
|
|
config ARCH_USE_S_MODE
|
2024-06-12 10:39:41 +08:00
|
|
|
bool "Run NuttX in S-mode"
|
2022-03-17 17:20:42 +08:00
|
|
|
default n
|
2024-06-12 10:39:41 +08:00
|
|
|
depends on ARCH_HAVE_S_MODE
|
2024-04-23 17:27:51 +08:00
|
|
|
select RISCV_PERCPU_SCRATCH
|
2022-03-17 17:20:42 +08:00
|
|
|
---help---
|
|
|
|
Most of the RISC-V implementations run in M-mode (flat addressing)
|
|
|
|
and/or U-mode (in case of separate kernel-/userspaces). This provides
|
|
|
|
an option to run the kernel in S-mode, if the target supports it.
|
|
|
|
|
2024-04-15 19:12:20 +08:00
|
|
|
config ARCH_RV_EXT_SSTC
|
|
|
|
bool "Enable RISC-V SSTC extension support"
|
|
|
|
default n
|
|
|
|
depends on ARCH_USE_S_MODE
|
|
|
|
|
2024-05-12 20:15:58 +08:00
|
|
|
config ARCH_RV_HAVE_APLIC
|
|
|
|
bool "Enable RISC-V Advanced Platform-Level Interrupt Controller support"
|
|
|
|
default n
|
|
|
|
---help---
|
|
|
|
Instead of PLIC, RISC-V also defines Advanced Platform-Level Interrupt
|
|
|
|
Controller (APLIC) to provide flexible interrupt control. This device
|
|
|
|
is not backward compatible with PLIC.
|
|
|
|
|
|
|
|
config ARCH_RV_EXT_AIA
|
|
|
|
bool "Enable RISC-V SxAIA support"
|
|
|
|
default n
|
|
|
|
---help---
|
|
|
|
Advanced Interrupt Architecture defines necessary features that
|
|
|
|
impact the ISA at a hart. This should not be selected if the
|
|
|
|
target does not support SxAIA for the operating mode of NuttX.
|
|
|
|
|
|
|
|
if ARCH_RV_EXT_AIA
|
|
|
|
|
|
|
|
config ARCH_RV_HAVE_IMSIC
|
|
|
|
bool "Enable RISC-V AIA Incoming Message Controller support"
|
|
|
|
default n
|
|
|
|
|
|
|
|
endif # ARCH_RV_EXT_AIA
|
|
|
|
|
2022-04-11 17:31:18 +08:00
|
|
|
choice
|
|
|
|
prompt "Toolchain Selection"
|
2023-03-08 21:05:56 +08:00
|
|
|
default RISCV_TOOLCHAIN_GNU_RV64
|
2022-04-11 17:31:18 +08:00
|
|
|
|
2023-03-08 21:05:56 +08:00
|
|
|
config RISCV_TOOLCHAIN_GNU_RV64
|
|
|
|
bool "Generic GNU RV64 toolchain"
|
2022-04-11 17:31:18 +08:00
|
|
|
select ARCH_TOOLCHAIN_GNU
|
|
|
|
---help---
|
|
|
|
This option should work for any modern GNU toolchain (GCC 5.2 or newer)
|
|
|
|
configured for riscv64-unknown-elf.
|
|
|
|
|
2023-03-08 21:05:56 +08:00
|
|
|
config RISCV_TOOLCHAIN_GNU_RV32
|
|
|
|
bool "Generic GNU RV32 toolchain"
|
|
|
|
select ARCH_TOOLCHAIN_GNU
|
|
|
|
---help---
|
|
|
|
This option should work for any modern GNU toolchain (GCC 5.2 or newer)
|
|
|
|
configured for riscv32-unknown-elf.
|
|
|
|
|
2024-04-18 14:01:18 +08:00
|
|
|
config RISCV_TOOLCHAIN_CLANG
|
|
|
|
bool "LLVM Clang toolchain"
|
|
|
|
select ARCH_TOOLCHAIN_CLANG
|
|
|
|
|
2024-06-08 08:45:28 +08:00
|
|
|
config RISCV_TOOLCHAIN_GNU_RV64ILP32
|
|
|
|
bool "Generic GNU RV64ILP32 toolchain"
|
|
|
|
select ARCH_TOOLCHAIN_GNU
|
|
|
|
select ARCH_RV64ILP32
|
|
|
|
---help---
|
|
|
|
This option work with Ruyisdk toolchain (GCC 13 or newer)
|
|
|
|
configured for riscv64-unknown-elf.
|
|
|
|
|
2024-04-08 22:21:13 +08:00
|
|
|
endchoice # Toolchain Selection
|
2022-04-11 17:31:18 +08:00
|
|
|
|
2022-05-02 17:00:26 +08:00
|
|
|
config RISCV_SEMIHOSTING_HOSTFS
|
|
|
|
bool "Semihosting HostFS"
|
|
|
|
depends on FS_HOSTFS
|
|
|
|
---help---
|
|
|
|
Mount HostFS through semihosting.
|
|
|
|
|
|
|
|
This doesn't support some directory operations like readdir because
|
|
|
|
of the limitations of semihosting mechanism.
|
|
|
|
|
|
|
|
if RISCV_SEMIHOSTING_HOSTFS
|
|
|
|
|
|
|
|
config RISCV_SEMIHOSTING_HOSTFS_CACHE_COHERENCE
|
|
|
|
bool "Cache coherence in semihosting hostfs"
|
|
|
|
depends on ARCH_DCACHE
|
|
|
|
---help---
|
|
|
|
Flush & Invalidte cache before & after bkpt instruction.
|
|
|
|
|
2024-04-08 22:21:13 +08:00
|
|
|
endif # RISCV_SEMIHOSTING_HOSTFS
|
2022-05-02 17:00:26 +08:00
|
|
|
|
2023-03-28 07:08:51 +08:00
|
|
|
if ARCH_CHIP_LITEX
|
|
|
|
|
|
|
|
choice
|
|
|
|
prompt "LITEX Core Selection"
|
|
|
|
default LITEX_CORE_VEXRISCV
|
|
|
|
|
|
|
|
config LITEX_CORE_VEXRISCV
|
|
|
|
bool "vexriscv core"
|
|
|
|
|
|
|
|
config LITEX_CORE_VEXRISCV_SMP
|
|
|
|
bool "vexriscv_smp core"
|
|
|
|
select ARCH_HAVE_MPU
|
|
|
|
select ARCH_RV_ISA_C
|
|
|
|
select ARCH_MMU_TYPE_SV32
|
|
|
|
select ARCH_HAVE_ADDRENV
|
|
|
|
select ARCH_NEED_ADDRENV_MAPPING
|
|
|
|
select ARCH_HAVE_S_MODE
|
2023-06-27 08:26:48 +08:00
|
|
|
select ARCH_HAVE_ELF_EXECUTABLE
|
2024-05-15 12:40:22 +08:00
|
|
|
select ARCH_HAVE_PERF_EVENTS
|
2023-03-28 07:08:51 +08:00
|
|
|
|
2024-04-08 22:21:13 +08:00
|
|
|
endchoice # LITEX Core Selection
|
2023-03-28 07:08:51 +08:00
|
|
|
|
2024-04-08 22:21:13 +08:00
|
|
|
endif # ARCH_CHIP_LITEX
|
2023-03-28 07:08:51 +08:00
|
|
|
|
2021-12-20 20:20:47 +08:00
|
|
|
source "arch/risc-v/src/opensbi/Kconfig"
|
2022-04-11 18:46:41 +08:00
|
|
|
source "arch/risc-v/src/nuttsbi/Kconfig"
|
2021-12-20 20:20:47 +08:00
|
|
|
|
2019-11-29 04:37:24 +08:00
|
|
|
if ARCH_CHIP_FE310
|
2021-07-20 19:10:10 +08:00
|
|
|
source "arch/risc-v/src/fe310/Kconfig"
|
2019-11-29 04:37:24 +08:00
|
|
|
endif
|
2019-12-31 23:06:20 +08:00
|
|
|
if ARCH_CHIP_K210
|
2021-07-20 19:10:10 +08:00
|
|
|
source "arch/risc-v/src/k210/Kconfig"
|
2019-12-31 23:06:20 +08:00
|
|
|
endif
|
2020-03-21 14:01:56 +08:00
|
|
|
if ARCH_CHIP_LITEX
|
2021-07-20 19:10:10 +08:00
|
|
|
source "arch/risc-v/src/litex/Kconfig"
|
2020-03-21 14:01:56 +08:00
|
|
|
endif
|
2020-12-17 19:04:46 +08:00
|
|
|
if ARCH_CHIP_BL602
|
2021-07-20 19:10:10 +08:00
|
|
|
source "arch/risc-v/src/bl602/Kconfig"
|
2020-12-17 19:04:46 +08:00
|
|
|
endif
|
2021-01-21 20:13:10 +08:00
|
|
|
if ARCH_CHIP_ESP32C3
|
2024-01-04 19:20:50 +08:00
|
|
|
source "arch/risc-v/src/esp32c3-legacy/Kconfig"
|
2021-01-21 20:13:10 +08:00
|
|
|
endif
|
2024-01-08 16:26:14 +08:00
|
|
|
if ARCH_CHIP_ESP32C3_GENERIC
|
|
|
|
source "arch/risc-v/src/esp32c3/Kconfig"
|
|
|
|
endif
|
|
|
|
if ARCH_CHIP_ESP32C6
|
|
|
|
source "arch/risc-v/src/esp32c6/Kconfig"
|
|
|
|
endif
|
|
|
|
if ARCH_CHIP_ESP32H2
|
|
|
|
source "arch/risc-v/src/esp32h2/Kconfig"
|
2023-01-24 21:31:15 +08:00
|
|
|
endif
|
2021-03-08 23:19:29 +08:00
|
|
|
if ARCH_CHIP_C906
|
2021-07-20 19:10:10 +08:00
|
|
|
source "arch/risc-v/src/c906/Kconfig"
|
2021-03-08 23:19:29 +08:00
|
|
|
endif
|
2021-05-04 18:56:52 +08:00
|
|
|
if ARCH_CHIP_MPFS
|
2021-07-20 19:10:10 +08:00
|
|
|
source "arch/risc-v/src/mpfs/Kconfig"
|
2021-05-04 18:56:52 +08:00
|
|
|
endif
|
2021-06-04 15:30:49 +08:00
|
|
|
if ARCH_CHIP_RV32M1
|
2021-07-20 19:10:10 +08:00
|
|
|
source "arch/risc-v/src/rv32m1/Kconfig"
|
2021-06-04 15:30:49 +08:00
|
|
|
endif
|
2022-01-14 17:18:29 +08:00
|
|
|
if ARCH_CHIP_QEMU_RV
|
|
|
|
source "arch/risc-v/src/qemu-rv/Kconfig"
|
2021-12-05 21:41:44 +08:00
|
|
|
endif
|
2024-02-18 15:13:03 +08:00
|
|
|
if ARCH_CHIP_HPM6000
|
|
|
|
source "arch/risc-v/src/hpm6000/Kconfig"
|
|
|
|
endif
|
2023-02-08 10:49:31 +08:00
|
|
|
if ARCH_CHIP_HPM6750
|
|
|
|
source "arch/risc-v/src/hpm6750/Kconfig"
|
|
|
|
endif
|
2023-08-04 07:31:14 +08:00
|
|
|
if ARCH_CHIP_JH7110
|
|
|
|
source "arch/risc-v/src/jh7110/Kconfig"
|
|
|
|
endif
|
2023-12-12 09:00:08 +08:00
|
|
|
if ARCH_CHIP_BL808
|
|
|
|
source "arch/risc-v/src/bl808/Kconfig"
|
|
|
|
endif
|
2023-12-13 10:59:21 +08:00
|
|
|
if ARCH_CHIP_K230
|
|
|
|
source "arch/risc-v/src/k230/Kconfig"
|
|
|
|
endif
|
2024-06-16 19:39:17 +08:00
|
|
|
if ARCH_CHIP_SG2000
|
|
|
|
source "arch/risc-v/src/sg2000/Kconfig"
|
|
|
|
endif
|
2024-04-08 22:21:13 +08:00
|
|
|
endif # ARCH_RISCV
|