From ebf43616b79b9ad08c3d74f6702e912f9c78733f Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Fri, 4 May 2018 15:44:29 +0200 Subject: [PATCH] cpu: add arch_* features --- Makefile.dep | 2 ++ cpu/arm7_common/Makefile.features | 3 +++ cpu/atmega_common/Makefile.features | 5 +++-- cpu/cortexm_common/Makefile.features | 3 +++ cpu/esp32/Makefile.features | 3 ++- cpu/esp8266/Makefile.features | 2 ++ cpu/mips32r2_common/Makefile.features | 2 ++ cpu/msp430_common/Makefile.features | 2 ++ cpu/native/Makefile.features | 2 ++ 9 files changed, 21 insertions(+), 3 deletions(-) diff --git a/Makefile.dep b/Makefile.dep index 670274401b..2355db32a3 100644 --- a/Makefile.dep +++ b/Makefile.dep @@ -979,6 +979,8 @@ FEATURES_OPTIONAL += periph_pm # include package dependencies -include $(USEPKG:%=$(RIOTPKG)/%/Makefile.dep) +# always select provided architecture features +FEATURES_REQUIRED += $(filter arch_%,$(FEATURES_PROVIDED)) # all periph features correspond to a periph submodule # FEATURES_USED is defined in Makefile.features diff --git a/cpu/arm7_common/Makefile.features b/cpu/arm7_common/Makefile.features index f1f8283904..78b65033f3 100644 --- a/cpu/arm7_common/Makefile.features +++ b/cpu/arm7_common/Makefile.features @@ -1,2 +1,5 @@ +FEATURES_PROVIDED += arch_32bit +FEATURES_PROVIDED += arch_arm +FEATURES_PROVIDED += arch_arm7 FEATURES_PROVIDED += cpp FEATURES_PROVIDED += periph_pm diff --git a/cpu/atmega_common/Makefile.features b/cpu/atmega_common/Makefile.features index 18cbcf576a..803b95c5c0 100644 --- a/cpu/atmega_common/Makefile.features +++ b/cpu/atmega_common/Makefile.features @@ -1,4 +1,5 @@ +FEATURES_PROVIDED += arch_8bit +FEATURES_PROVIDED += arch_avr8 +FEATURES_PROVIDED += atmega_pcint0 FEATURES_PROVIDED += periph_eeprom FEATURES_PROVIDED += periph_pm - -FEATURES_PROVIDED += atmega_pcint0 diff --git a/cpu/cortexm_common/Makefile.features b/cpu/cortexm_common/Makefile.features index dfc9ccd52a..c267c7240e 100644 --- a/cpu/cortexm_common/Makefile.features +++ b/cpu/cortexm_common/Makefile.features @@ -1,3 +1,6 @@ +FEATURES_PROVIDED += arch_32bit +FEATURES_PROVIDED += arch_arm +FEATURES_PROVIDED += arch_cortexm FEATURES_PROVIDED += periph_pm FEATURES_PROVIDED += cpp FEATURES_PROVIDED += cpu_check_address diff --git a/cpu/esp32/Makefile.features b/cpu/esp32/Makefile.features index c92dd9f24f..f537631637 100644 --- a/cpu/esp32/Makefile.features +++ b/cpu/esp32/Makefile.features @@ -1,4 +1,5 @@ -# Features that are provided by the CPU independent on the board +FEATURES_PROVIDED += arch_32bit +FEATURES_PROVIDED += arch_esp32 FEATURES_PROVIDED += cpp FEATURES_PROVIDED += periph_cpuid FEATURES_PROVIDED += periph_hwrng diff --git a/cpu/esp8266/Makefile.features b/cpu/esp8266/Makefile.features index d4defe30be..3c3c6579de 100644 --- a/cpu/esp8266/Makefile.features +++ b/cpu/esp8266/Makefile.features @@ -1,5 +1,7 @@ # MCU defined features that are provided independent on board definitions +FEATURES_PROVIDED += arch_32bit +FEATURES_PROVIDED += arch_esp8266 FEATURES_PROVIDED += periph_cpuid FEATURES_PROVIDED += periph_hwrng FEATURES_PROVIDED += periph_pm diff --git a/cpu/mips32r2_common/Makefile.features b/cpu/mips32r2_common/Makefile.features index f1f8283904..da355d8b12 100644 --- a/cpu/mips32r2_common/Makefile.features +++ b/cpu/mips32r2_common/Makefile.features @@ -1,2 +1,4 @@ +FEATURES_PROVIDED += arch_32bit +FEATURES_PROVIDED += arch_mips32r2 FEATURES_PROVIDED += cpp FEATURES_PROVIDED += periph_pm diff --git a/cpu/msp430_common/Makefile.features b/cpu/msp430_common/Makefile.features index 15cb270bb0..5d44f0f698 100644 --- a/cpu/msp430_common/Makefile.features +++ b/cpu/msp430_common/Makefile.features @@ -1,2 +1,4 @@ +FEATURES_PROVIDED += arch_16bit +FEATURES_PROVIDED += arch_msp430 FEATURES_PROVIDED += periph_flashpage FEATURES_PROVIDED += periph_pm diff --git a/cpu/native/Makefile.features b/cpu/native/Makefile.features index 9e0823bd94..638a8f0f06 100644 --- a/cpu/native/Makefile.features +++ b/cpu/native/Makefile.features @@ -1,3 +1,5 @@ +FEATURES_PROVIDED += arch_32bit +FEATURES_PROVIDED += arch_native FEATURES_PROVIDED += cpp FEATURES_PROVIDED += periph_cpuid FEATURES_PROVIDED += periph_hwrng