arm/Kconfig: add cortex-m85 config

Signed-off-by: wangbowen6 <wangbowen6@xiaomi.com>
This commit is contained in:
wangbowen6 2022-12-08 15:09:55 +08:00 committed by Xiang Xiao
parent ee72f920a3
commit 27ea9f7625
2 changed files with 47 additions and 0 deletions

View File

@ -910,6 +910,23 @@ config ARCH_CORTEXM55
select ARCH_HAVE_USAGEFAULT_DEBUG
select ARCH_HAVE_SECUREFAULT_DEBUG if ARCH_TRUSTZONE_SECURE
config ARCH_CORTEXM85
bool
default n
select ARM_THUMB
select ARCH_ARMV8M
select ARCH_HAVE_IRQPRIO
select ARCH_HAVE_IRQTRIGGER
select ARCH_HAVE_RAMVECTORS
select ARCH_HAVE_HIPRI_INTERRUPT
select ARCH_HAVE_RESET
select ARCH_HAVE_TESTSET
select ARCH_HAVE_HARDFAULT_DEBUG
select ARCH_HAVE_MEMFAULT_DEBUG
select ARCH_HAVE_BUSFAULT_DEBUG
select ARCH_HAVE_USAGEFAULT_DEBUG
select ARCH_HAVE_SECUREFAULT_DEBUG if ARCH_TRUSTZONE_SECURE
config ARCH_FAMILY
string
default "arm" if ARCH_ARM7TDMI || ARCH_ARM920T || ARCH_ARM926EJS || ARCH_ARM1136J || ARCH_ARM1156T2 || ARCH_ARM1176JZ

View File

@ -46,6 +46,16 @@ else ifeq ($(CONFIG_ARCH_CORTEXM55),y)
ifeq ($(CONFIG_ARCH_FPU),y)
TOOLCHAIN_MFLOAT := -mfpu=fpv5-d16
endif
else ifeq ($(CONFIG_ARCH_CORTEXM85),y)
TOOLCHAIN_MTUNE := -mtune=cortex-m85
ifeq ($(CONFIG_ARM_HAVE_MVE),y)
TOOLCHAIN_MARCH := -march=armv8.1-m.main+mve.fp+fp.dp
else
TOOLCHAIN_MARCH := -march=armv8.1-m.main$(EXTCPUFLAGS)
endif
ifeq ($(CONFIG_ARCH_FPU),y)
TOOLCHAIN_MFLOAT := -mfpu=fpv5-d16
endif
endif
ifeq ($(CONFIG_ARCH_FPU),y)
@ -82,6 +92,12 @@ ifeq ($(CONFIG_ARM_TOOLCHAIN_CLANG),y)
else
TOOLCHAIN_MARCH += --config armv8.1m.main_soft_nofp_nomve_nosys
endif
else ifeq ($(CONFIG_ARCH_CORTEXM85),y)
ifeq ($(CONFIG_ARCH_FPU),y)
TOOLCHAIN_MARCH += --config armv8.1m.main_hard_fp
else
TOOLCHAIN_MARCH += --config armv8.1m.main_soft_nofp_nomve
endif
endif
else ifeq ($(CONFIG_ARM_TOOLCHAIN_ARMCLANG),y)
@ -114,6 +130,20 @@ else ifeq ($(CONFIG_ARM_TOOLCHAIN_ARMCLANG),y)
LDFLAGS += --cpu=Cortex-M55.no_mve.no_fp
endif
endif
else ifeq ($(CONFIG_ARCH_CORTEXM85),y)
ifeq ($(CONFIG_ARM_HAVE_MVE),y)
ifeq ($(CONFIG_ARCH_FPU),y)
LDFLAGS += --cpu=Cortex-M85
else
LDFLAGS += --cpu=Cortex-M85.no_fp
endif
else
ifeq ($(CONFIG_ARCH_FPU),y)
LDFLAGS += --cpu=Cortex-M85.no_mve
else
LDFLAGS += --cpu=Cortex-M85.no_mve.no_fp
endif
endif
endif
endif