From c71c2b79a7a9416646eaba509a3c1576b967fb7f Mon Sep 17 00:00:00 2001 From: Leandro Lanzieri Date: Thu, 9 Jul 2020 09:44:36 +0200 Subject: [PATCH] cpu/arm7_common: Add Kconfig symbols HAS_ARCH_ARM features now is moved to Kconfig.features as it is being used by multiple architectures. --- cpu/arm7_common/Kconfig | 33 +++++++++++++++++++++++++++++++ cpu/arm7_common/Makefile.features | 3 +++ cpu/cortexm_common/Kconfig | 5 ----- kconfigs/Kconfig.features | 5 +++++ 4 files changed, 41 insertions(+), 5 deletions(-) create mode 100644 cpu/arm7_common/Kconfig diff --git a/cpu/arm7_common/Kconfig b/cpu/arm7_common/Kconfig new file mode 100644 index 0000000000..e1b7c408d5 --- /dev/null +++ b/cpu/arm7_common/Kconfig @@ -0,0 +1,33 @@ +# Copyright (c) 2020 HAW Hamburg +# +# This file is subject to the terms and conditions of the GNU Lesser +# General Public License v2.1. See the file LICENSE in the top level +# directory for more details. +# + +config CPU_ARCH_ARMV4T + bool + select HAS_ARCH_32BIT + select HAS_ARCH_ARM + select HAS_CPP + +config CPU_CORE_ARM7TDMI_S + bool + select CPU_ARCH_ARMV4T + select HAS_ARCH_ARM7 + select HAS_PERIPH_PM + select HAS_PUF_SRAM + select HAS_SSP + +## Declaration of specific features +config HAS_ARCH_ARM7 + bool + help + Indicates that the core is part of the ARM7 group of cores. + +## Common CPU symbols +config CPU_ARCH + default "armv4t" if CPU_ARCH_ARMV4T + +config CPU_CORE + default "arm7tdmi_s" if CPU_CORE_ARM7TDMI_S diff --git a/cpu/arm7_common/Makefile.features b/cpu/arm7_common/Makefile.features index 5183414c71..e6c718a197 100644 --- a/cpu/arm7_common/Makefile.features +++ b/cpu/arm7_common/Makefile.features @@ -1,3 +1,6 @@ +CPU_ARCH = armv4t +CPU_CORE = arm7tdmi_s + FEATURES_PROVIDED += arch_32bit FEATURES_PROVIDED += arch_arm FEATURES_PROVIDED += arch_arm7 diff --git a/cpu/cortexm_common/Kconfig b/cpu/cortexm_common/Kconfig index 271d23c0ed..63657b49b5 100644 --- a/cpu/cortexm_common/Kconfig +++ b/cpu/cortexm_common/Kconfig @@ -88,11 +88,6 @@ config HAS_CPU_CORE_CORTEXM help Indicates that the current CPU has an ARM Cortex-M core. -config HAS_ARCH_ARM - bool - help - Indicates that the current architecture is ARM. - config HAS_CORTEXM_FPU bool help diff --git a/kconfigs/Kconfig.features b/kconfigs/Kconfig.features index 6c742780c5..c29a64f60f 100644 --- a/kconfigs/Kconfig.features +++ b/kconfigs/Kconfig.features @@ -22,6 +22,11 @@ config HAS_ARCH_32BIT help Indicates that the CPU has a 32-bits architecture. +config HAS_ARCH_ARM + bool + help + Indicates that the current architecture is ARM. + config HAS_ARDUINO bool help