diff --git a/boards/b-l072z-lrwan1/Makefile.features b/boards/b-l072z-lrwan1/Makefile.features index 9873156f7e6b..2145bd24a7e2 100644 --- a/boards/b-l072z-lrwan1/Makefile.features +++ b/boards/b-l072z-lrwan1/Makefile.features @@ -11,7 +11,5 @@ FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart # Put other features for this board (in alphabetical order) -# For riotboot you need an openocd that supports dualbank flashing. -# The 0.10.0 openocd version in Ubuntu Bionic doesn't work. The change was -# introduced after Jun 8, 2017 - v0.10.0-1-20170607-2132-dev. +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot diff --git a/boards/cc2538dk/Makefile.features b/boards/cc2538dk/Makefile.features index 41787bca085b..2021b6efef68 100644 --- a/boards/cc2538dk/Makefile.features +++ b/boards/cc2538dk/Makefile.features @@ -11,4 +11,5 @@ FEATURES_PROVIDED += periph_uart # Various other features (if any) FEATURES_PROVIDED += emulator_renode +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot diff --git a/boards/common/esp32x/Makefile.dep b/boards/common/esp32x/Makefile.dep index d406950ee5cd..d4ad27b75285 100644 --- a/boards/common/esp32x/Makefile.dep +++ b/boards/common/esp32x/Makefile.dep @@ -1,5 +1 @@ USEMODULE += boards_common_esp32x - -ifneq (,$(filter saul_default,$(USEMODULE))) - USEMODULE += saul_gpio -endif diff --git a/boards/common/iotlab/Makefile.features b/boards/common/iotlab/Makefile.features index 455b73500d7b..585c145de0d2 100644 --- a/boards/common/iotlab/Makefile.features +++ b/boards/common/iotlab/Makefile.features @@ -11,3 +11,4 @@ FEATURES_PROVIDED += periph_uart # Put other features for this board (in alphabetical order) FEATURES_PROVIDED += riotboot +FEATURES_PROVIDED += netif diff --git a/boards/common/kw41z/Makefile.features b/boards/common/kw41z/Makefile.features index bebaefb16337..3d0dc51357e5 100644 --- a/boards/common/kw41z/Makefile.features +++ b/boards/common/kw41z/Makefile.features @@ -9,4 +9,5 @@ FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot diff --git a/boards/common/nrf52/Makefile.features b/boards/common/nrf52/Makefile.features index 21880d84cffa..05c6c970d348 100644 --- a/boards/common/nrf52/Makefile.features +++ b/boards/common/nrf52/Makefile.features @@ -3,4 +3,7 @@ CPU = nrf52 # Put defined MCU peripherals here (in alphabetical order) FEATURES_PROVIDED += periph_rtt FEATURES_PROVIDED += periph_timer + +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot diff --git a/boards/esp32-ethernet-kit-v1_0/Makefile.dep b/boards/esp32-ethernet-kit-v1_0/Makefile.dep index 1b7c4590a759..8b7842afa32e 100644 --- a/boards/esp32-ethernet-kit-v1_0/Makefile.dep +++ b/boards/esp32-ethernet-kit-v1_0/Makefile.dep @@ -4,3 +4,13 @@ include $(RIOTBOARD)/common/esp32/Makefile.dep ifneq (,$(filter netdev_default,$(USEMODULE))) USEMODULE += esp_eth endif + +# saul_gpio does conflict eth, as the only SAUL enabled GPIO is the boot button. +# But that GPIO doubles as phy clock input. +ifneq (,$(filter esp_eth,$(USEMODULE))) + DISABLE_MODULE += saul_gpio +endif + +ifneq (,$(filter saul_default,$(USEMODULE))) + DEFAULT_MODULE += saul_gpio +endif diff --git a/boards/esp32-heltec-lora32-v2/Makefile.dep b/boards/esp32-heltec-lora32-v2/Makefile.dep index e8b2b0b3b2c1..f236876e4067 100644 --- a/boards/esp32-heltec-lora32-v2/Makefile.dep +++ b/boards/esp32-heltec-lora32-v2/Makefile.dep @@ -2,4 +2,8 @@ ifneq (,$(filter netdev_default,$(USEMODULE))) USEMODULE += sx1276 endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32/Makefile.dep diff --git a/boards/esp32-mh-et-live-minikit/Makefile.dep b/boards/esp32-mh-et-live-minikit/Makefile.dep index 9b22e1fdcbfd..714868b61949 100644 --- a/boards/esp32-mh-et-live-minikit/Makefile.dep +++ b/boards/esp32-mh-et-live-minikit/Makefile.dep @@ -10,4 +10,8 @@ ifneq (,$(filter sdcard_spi,$(USEMODULE))) endif endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32/Makefile.dep diff --git a/boards/esp32-ttgo-t-beam/Makefile.dep b/boards/esp32-ttgo-t-beam/Makefile.dep index 6c6d30e82b80..371b1e06b0db 100644 --- a/boards/esp32-ttgo-t-beam/Makefile.dep +++ b/boards/esp32-ttgo-t-beam/Makefile.dep @@ -2,4 +2,8 @@ ifneq (,$(filter esp32_ttgo_t_beam_v1_0,$(USEMODULE))) FEATURES_REQUIRED += periph_i2c endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32/Makefile.dep diff --git a/boards/esp32-wemos-lolin-d32-pro/Makefile.dep b/boards/esp32-wemos-lolin-d32-pro/Makefile.dep index 0dfe0effb01d..81fe57b33a8a 100644 --- a/boards/esp32-wemos-lolin-d32-pro/Makefile.dep +++ b/boards/esp32-wemos-lolin-d32-pro/Makefile.dep @@ -8,4 +8,8 @@ ifneq (,$(filter vfs_default,$(USEMODULE))) USEMODULE += mtd endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32/Makefile.dep diff --git a/boards/esp32-wroom-32/Makefile.dep b/boards/esp32-wroom-32/Makefile.dep index 29d6c99ba8ee..2c4f9792d812 100644 --- a/boards/esp32-wroom-32/Makefile.dep +++ b/boards/esp32-wroom-32/Makefile.dep @@ -1 +1,5 @@ include $(RIOTBOARD)/common/esp32/Makefile.dep + +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif diff --git a/boards/esp32-wrover-kit/Makefile.dep b/boards/esp32-wrover-kit/Makefile.dep index 5c610ad04811..1ee4b26c17d4 100644 --- a/boards/esp32-wrover-kit/Makefile.dep +++ b/boards/esp32-wrover-kit/Makefile.dep @@ -18,4 +18,8 @@ ifneq (,$(filter mtd,$(USEMODULE))) endif endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32/Makefile.dep diff --git a/boards/esp32c3-devkit/Makefile.dep b/boards/esp32c3-devkit/Makefile.dep index ddb6c4c86fb0..a15809229722 100644 --- a/boards/esp32c3-devkit/Makefile.dep +++ b/boards/esp32c3-devkit/Makefile.dep @@ -1 +1,5 @@ include $(RIOTBOARD)/common/esp32c3/Makefile.dep + +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif diff --git a/boards/esp32c3-wemos-mini/Makefile.dep b/boards/esp32c3-wemos-mini/Makefile.dep index 063d72f638d5..2b25c2a442a9 100644 --- a/boards/esp32c3-wemos-mini/Makefile.dep +++ b/boards/esp32c3-wemos-mini/Makefile.dep @@ -7,4 +7,8 @@ ifeq (,$(filter esp32c3_wemos_mini_v%,$(USEMODULE))) USEMODULE += esp32c3_wemos_mini_v2_1_0 endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32c3/Makefile.dep diff --git a/boards/esp32s2-devkit/Makefile.dep b/boards/esp32s2-devkit/Makefile.dep index 69cb028fd6d2..91ac3df7081e 100644 --- a/boards/esp32s2-devkit/Makefile.dep +++ b/boards/esp32s2-devkit/Makefile.dep @@ -1 +1,5 @@ include $(RIOTBOARD)/common/esp32s2/Makefile.dep + +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif diff --git a/boards/esp32s2-lilygo-ttgo-t8/Makefile.dep b/boards/esp32s2-lilygo-ttgo-t8/Makefile.dep index 9756eae97c88..ff14e2483dc1 100644 --- a/boards/esp32s2-lilygo-ttgo-t8/Makefile.dep +++ b/boards/esp32s2-lilygo-ttgo-t8/Makefile.dep @@ -16,4 +16,8 @@ ifneq (,$(filter disp_dev,$(USEMODULE))) USEMODULE += st7789 endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32s2/Makefile.dep diff --git a/boards/esp32s2-wemos-mini/Makefile.dep b/boards/esp32s2-wemos-mini/Makefile.dep index d6656ade1c24..89a525ccf038 100644 --- a/boards/esp32s2-wemos-mini/Makefile.dep +++ b/boards/esp32s2-wemos-mini/Makefile.dep @@ -1,2 +1,6 @@ include $(RIOTBOARD)/common/makefiles/stdio_tinyusb_cdc_acm.dep.mk include $(RIOTBOARD)/common/esp32s2/Makefile.dep + +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif diff --git a/boards/esp32s3-box/Makefile.dep b/boards/esp32s3-box/Makefile.dep index 375667ef06ba..1c09d058f4b8 100644 --- a/boards/esp32s3-box/Makefile.dep +++ b/boards/esp32s3-box/Makefile.dep @@ -14,5 +14,9 @@ ifneq (,$(filter disp_dev,$(USEMODULE))) USEMODULE += ili9341 endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32s3/Makefile.dep include $(RIOTBOARD)/common/makefiles/stdio_cdc_acm.dep.mk diff --git a/boards/esp32s3-devkit/Makefile.dep b/boards/esp32s3-devkit/Makefile.dep index 9b2d10be5953..e0fb1d1e0d53 100644 --- a/boards/esp32s3-devkit/Makefile.dep +++ b/boards/esp32s3-devkit/Makefile.dep @@ -1 +1,5 @@ include $(RIOTBOARD)/common/esp32s3/Makefile.dep + +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif diff --git a/boards/esp32s3-pros3/Makefile.dep b/boards/esp32s3-pros3/Makefile.dep index c2e382f787b9..4159038b8def 100644 --- a/boards/esp32s3-pros3/Makefile.dep +++ b/boards/esp32s3-pros3/Makefile.dep @@ -10,5 +10,9 @@ ifeq (,$(filter stdio_% slipdev_stdio usbus usbus% tinyusb_device,$(USEMODULE))) include $(RIOTMAKE)/tools/usb_board_reset.mk endif +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif + include $(RIOTBOARD)/common/esp32s3/Makefile.dep include $(RIOTBOARD)/common/makefiles/stdio_cdc_acm.dep.mk diff --git a/boards/esp32s3-usb-otg/Makefile.dep b/boards/esp32s3-usb-otg/Makefile.dep index b2e197237064..88ec8eaa8b3c 100644 --- a/boards/esp32s3-usb-otg/Makefile.dep +++ b/boards/esp32s3-usb-otg/Makefile.dep @@ -26,3 +26,7 @@ endif ifneq (,$(filter disp_dev,$(USEMODULE))) USEMODULE += st7789 endif + +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif diff --git a/boards/esp32s3-wt32-sc01-plus/Makefile.dep b/boards/esp32s3-wt32-sc01-plus/Makefile.dep index 42899babefa3..0128b651b3ea 100644 --- a/boards/esp32s3-wt32-sc01-plus/Makefile.dep +++ b/boards/esp32s3-wt32-sc01-plus/Makefile.dep @@ -39,3 +39,7 @@ endif ifneq (,$(filter periph_i2c,$(USEMODULE))) USEMODULE += esp_i2c_hw endif + +ifneq (,$(filter saul_default,$(USEMODULE))) + USEMODULE += saul_gpio +endif diff --git a/boards/hamilton/Makefile.features b/boards/hamilton/Makefile.features index d22e086b51db..abee17d6186d 100644 --- a/boards/hamilton/Makefile.features +++ b/boards/hamilton/Makefile.features @@ -10,3 +10,6 @@ FEATURES_PROVIDED += periph_rtc FEATURES_PROVIDED += periph_rtt FEATURES_PROVIDED += periph_spi FEATURES_PROVIDED += periph_timer + +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/boards/hip-badge/Makefile.dep b/boards/hip-badge/Makefile.dep index 5c958fbbf8dd..840d0a4ca897 100644 --- a/boards/hip-badge/Makefile.dep +++ b/boards/hip-badge/Makefile.dep @@ -4,6 +4,7 @@ endif ifneq (,$(filter saul_default,$(USEMODULE))) USEMODULE += sgp30 + USEMODULE += saul_gpio endif include $(RIOTBOARD)/common/esp32c3/Makefile.dep diff --git a/boards/lobaro-lorabox/Makefile.features b/boards/lobaro-lorabox/Makefile.features index f4e71d2cd87c..2b2611ba6e25 100644 --- a/boards/lobaro-lorabox/Makefile.features +++ b/boards/lobaro-lorabox/Makefile.features @@ -7,3 +7,6 @@ FEATURES_PROVIDED += periph_rtc FEATURES_PROVIDED += periph_spi periph_spi_gpio_mode FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart + +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/boards/lora-e5-dev/Makefile.features b/boards/lora-e5-dev/Makefile.features index df60c40d433b..424bffac743f 100644 --- a/boards/lora-e5-dev/Makefile.features +++ b/boards/lora-e5-dev/Makefile.features @@ -13,3 +13,4 @@ FEATURES_PROVIDED += periph_uart # Put other features for this board (in alphabetical order) FEATURES_PROVIDED += arduino_pins FEATURES_PROVIDED += riotboot +FEATURES_PROVIDED += netif diff --git a/boards/lsn50/Makefile.features b/boards/lsn50/Makefile.features index 9873156f7e6b..a9a8974d606f 100644 --- a/boards/lsn50/Makefile.features +++ b/boards/lsn50/Makefile.features @@ -11,7 +11,5 @@ FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart # Put other features for this board (in alphabetical order) -# For riotboot you need an openocd that supports dualbank flashing. -# The 0.10.0 openocd version in Ubuntu Bionic doesn't work. The change was -# introduced after Jun 8, 2017 - v0.10.0-1-20170607-2132-dev. FEATURES_PROVIDED += riotboot +FEATURES_PROVIDED += netif diff --git a/boards/mulle/Makefile.features b/boards/mulle/Makefile.features index 289831897155..e520bff1134f 100644 --- a/boards/mulle/Makefile.features +++ b/boards/mulle/Makefile.features @@ -18,3 +18,6 @@ FEATURES_PROVIDED += periph_rtt FEATURES_PROVIDED += periph_spi FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart + +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/boards/native/common_features.inc.mk b/boards/native/common_features.inc.mk index cbebc1102062..f65b720e62fd 100644 --- a/boards/native/common_features.inc.mk +++ b/boards/native/common_features.inc.mk @@ -7,6 +7,7 @@ FEATURES_PROVIDED += periph_gpio FEATURES_PROVIDED += periph_pwm FEATURES_PROVIDED += periph_qdec -# Various other features (if any) +# Put other features for this board (in alphabetical order) FEATURES_PROVIDED += ethernet FEATURES_PROVIDED += motor_driver +FEATURES_PROVIDED += netif diff --git a/boards/nucleo-f207zg/Makefile.features b/boards/nucleo-f207zg/Makefile.features index ebf78f92ed44..b0d25d5ce00e 100644 --- a/boards/nucleo-f207zg/Makefile.features +++ b/boards/nucleo-f207zg/Makefile.features @@ -14,6 +14,8 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += ethernet +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot FEATURES_PROVIDED += tinyusb_device diff --git a/boards/nucleo-f429zi/Makefile.features b/boards/nucleo-f429zi/Makefile.features index 92e2f945a8a9..e411743eb1ad 100644 --- a/boards/nucleo-f429zi/Makefile.features +++ b/boards/nucleo-f429zi/Makefile.features @@ -14,6 +14,8 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += ethernet +FEATURES_PROVIDED += netif FEATURES_PROVIDED += tinyusb_device # load the common Makefile.features for Nucleo boards diff --git a/boards/nucleo-f439zi/Makefile.features b/boards/nucleo-f439zi/Makefile.features index 8abb89362d09..b3c6be29c178 100644 --- a/boards/nucleo-f439zi/Makefile.features +++ b/boards/nucleo-f439zi/Makefile.features @@ -13,6 +13,8 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += ethernet +FEATURES_PROVIDED += netif FEATURES_PROVIDED += tinyusb_device # load the common Makefile.features for Nucleo boards diff --git a/boards/nucleo-f767zi/Makefile.features b/boards/nucleo-f767zi/Makefile.features index 94380f44bd5a..aa9175df155b 100644 --- a/boards/nucleo-f767zi/Makefile.features +++ b/boards/nucleo-f767zi/Makefile.features @@ -20,6 +20,8 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += ethernet +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot FEATURES_PROVIDED += tinyusb_device diff --git a/boards/nucleo-wl55jc/Makefile.features b/boards/nucleo-wl55jc/Makefile.features index a567d845b88f..6a9645d1aee2 100644 --- a/boards/nucleo-wl55jc/Makefile.features +++ b/boards/nucleo-wl55jc/Makefile.features @@ -11,6 +11,7 @@ FEATURES_PROVIDED += periph_uart # Put other features for this board (in alphabetical order) FEATURES_PROVIDED += riotboot +FEATURES_PROVIDED += netif # load the common Makefile.features for Nucleo boards include $(RIOTBOARD)/common/nucleo64/Makefile.features diff --git a/boards/openlabs-kw41z-mini/Makefile.features b/boards/openlabs-kw41z-mini/Makefile.features index ffcdc24beae2..4e052296d81f 100644 --- a/boards/openlabs-kw41z-mini/Makefile.features +++ b/boards/openlabs-kw41z-mini/Makefile.features @@ -13,3 +13,6 @@ FEATURES_PROVIDED += periph_spi FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += riotboot + +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/boards/pba-d-01-kw2x/Makefile.features b/boards/pba-d-01-kw2x/Makefile.features index 71754e01eca4..67c66a5d4eab 100644 --- a/boards/pba-d-01-kw2x/Makefile.features +++ b/boards/pba-d-01-kw2x/Makefile.features @@ -15,3 +15,4 @@ FEATURES_PROVIDED += periph_uart # Put other features for this board (in alphabetical order) FEATURES_PROVIDED += riotboot +FEATURES_PROVIDED += netif diff --git a/boards/same54-xpro/Makefile.features b/boards/same54-xpro/Makefile.features index ecf8e7b7f0b4..fb56f6949b9f 100644 --- a/boards/same54-xpro/Makefile.features +++ b/boards/same54-xpro/Makefile.features @@ -19,5 +19,7 @@ FEATURES_PROVIDED += periph_freqm FEATURES_PROVIDED += periph_can # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += ethernet +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot FEATURES_PROVIDED += tinyusb_device diff --git a/boards/samr21-xpro/Makefile.features b/boards/samr21-xpro/Makefile.features index 6bcdee23daa3..632f01d34c22 100644 --- a/boards/samr21-xpro/Makefile.features +++ b/boards/samr21-xpro/Makefile.features @@ -14,5 +14,6 @@ FEATURES_PROVIDED += periph_uart_hw_fc FEATURES_PROVIDED += periph_usbdev # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot FEATURES_PROVIDED += tinyusb_device diff --git a/boards/samr30-xpro/Makefile.features b/boards/samr30-xpro/Makefile.features index f2b7cf9c316b..4ecf0e4d35a0 100644 --- a/boards/samr30-xpro/Makefile.features +++ b/boards/samr30-xpro/Makefile.features @@ -12,5 +12,6 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif FEATURES_PROVIDED += riotboot FEATURES_PROVIDED += tinyusb_device diff --git a/boards/spark-core/Makefile.features b/boards/spark-core/Makefile.features index 17b018e591ef..143ffe8c1131 100644 --- a/boards/spark-core/Makefile.features +++ b/boards/spark-core/Makefile.features @@ -5,3 +5,6 @@ CPU_MODEL = stm32f103cb FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_spi FEATURES_PROVIDED += periph_uart + +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/boards/stm32f746g-disco/features-shared.mk b/boards/stm32f746g-disco/features-shared.mk index d025e3fd61f3..6dd03f081e2d 100644 --- a/boards/stm32f746g-disco/features-shared.mk +++ b/boards/stm32f746g-disco/features-shared.mk @@ -15,4 +15,8 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev FEATURES_PROVIDED += periph_usbdev_hs FEATURES_PROVIDED += periph_usbdev_hs_ulpi + +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += ethernet +FEATURES_PROVIDED += netif FEATURES_PROVIDED += tinyusb_device diff --git a/boards/telosb/Makefile.features b/boards/telosb/Makefile.features index 3a6410cfab09..02eb0b98c819 100644 --- a/boards/telosb/Makefile.features +++ b/boards/telosb/Makefile.features @@ -7,4 +7,5 @@ FEATURES_PROVIDED += periph_spi FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart -# Various other features (if any) +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/boards/z1/Makefile.features b/boards/z1/Makefile.features index fc3612506ddb..9d29499dc798 100644 --- a/boards/z1/Makefile.features +++ b/boards/z1/Makefile.features @@ -7,4 +7,5 @@ FEATURES_PROVIDED += periph_spi FEATURES_PROVIDED += periph_timer FEATURES_PROVIDED += periph_uart -# Various other features (if any) +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/boards/zigduino/Makefile.features b/boards/zigduino/Makefile.features index fa4a875f7bb5..26f3fed3490c 100644 --- a/boards/zigduino/Makefile.features +++ b/boards/zigduino/Makefile.features @@ -12,3 +12,6 @@ FEATURES_PROVIDED += periph_uart # Put defined MCU peripherals here (in alphabetical order) # Peripherals are defined in common/arduino-atmega/Makefile.features # Add only additional Peripherals +# +# Put other features for this board (in alphabetical order) +FEATURES_PROVIDED += netif diff --git a/cpu/atmega128rfa1/Makefile.features b/cpu/atmega128rfa1/Makefile.features index 664dcf9dd6de..3475fe1950b2 100644 --- a/cpu/atmega128rfa1/Makefile.features +++ b/cpu/atmega128rfa1/Makefile.features @@ -4,3 +4,6 @@ include $(RIOTCPU)/atmega_common/Makefile.features # additional PCINT for atmega128rfa1 FEATURES_PROVIDED += atmega_pcint1 + +# MCU has a peripheral network interface +FEATURES_PROVIDED += netif diff --git a/cpu/atmega256rfr2/Makefile.features b/cpu/atmega256rfr2/Makefile.features index 5bd4ab1d37b7..af4d2f0a9526 100644 --- a/cpu/atmega256rfr2/Makefile.features +++ b/cpu/atmega256rfr2/Makefile.features @@ -4,3 +4,6 @@ include $(RIOTCPU)/atmega_common/Makefile.features # additional PCINT for atmega256rfr2 FEATURES_PROVIDED += atmega_pcint1 + +# MCU has a peripheral network interface +FEATURES_PROVIDED += netif diff --git a/cpu/cc2538/Makefile.features b/cpu/cc2538/Makefile.features index 976e8c4e8a3e..b4a08c729765 100644 --- a/cpu/cc2538/Makefile.features +++ b/cpu/cc2538/Makefile.features @@ -15,4 +15,7 @@ FEATURES_PROVIDED += periph_wdt FEATURES_PROVIDED += cortexm_mpu +# MCU has a peripheral network interface +FEATURES_PROVIDED += netif + include $(RIOTCPU)/cortexm_common/Makefile.features diff --git a/cpu/esp_common/Makefile.features b/cpu/esp_common/Makefile.features index c15babdec883..6180672cddd8 100644 --- a/cpu/esp_common/Makefile.features +++ b/cpu/esp_common/Makefile.features @@ -30,5 +30,8 @@ ifeq (rv32,$(CPU_ARCH)) FEATURES_PROVIDED += arch_esp_riscv endif +# All ESP* MCUs have a peripheral network interface +FEATURES_PROVIDED += netif + FEATURES_CONFLICT += esp_wifi_ap:esp_now FEATURES_CONFLICT_MSG += "ESP_NOW and ESP_WIFI_AP can not be used at the same time." diff --git a/cpu/nrf5x_common/Makefile.features b/cpu/nrf5x_common/Makefile.features index 2779a606568d..806a925e81d6 100644 --- a/cpu/nrf5x_common/Makefile.features +++ b/cpu/nrf5x_common/Makefile.features @@ -33,6 +33,7 @@ ifeq (,$(filter nrf9160 nrf5340_app,$(CPU_MODEL))) FEATURES_PROVIDED += ble_nimble FEATURES_PROVIDED += radio_nrfble FEATURES_PROVIDED += radio_nrfmin + FEATURES_PROVIDED += netif endif include $(RIOTCPU)/cortexm_common/Makefile.features diff --git a/examples/default/Makefile b/examples/default/Makefile index 4442f7e7248a..81dbbe614c6d 100644 --- a/examples/default/Makefile +++ b/examples/default/Makefile @@ -34,20 +34,10 @@ USEMODULE += ps # include and auto-initialize all available sensors USEMODULE += saul_default -include $(RIOTBASE)/tests/Makefile.boards.netif -ifneq (,$(filter $(BOARD),$(BOARD_PROVIDES_NETIF))) - # Use modules for networking - # gnrc is a meta module including all required, basic gnrc networking modules - USEMODULE += gnrc - # use the default network interface for the board - USEMODULE += netdev_default - # automatically initialize the network interface - USEMODULE += auto_init_gnrc_netif - # shell command to send L2 packets with a simple string - USEMODULE += gnrc_txtsnd - # the application dumps received packets to stdout - USEMODULE += gnrc_pktdump -endif +# Use a network interface, if available. The handling is done in +# Makefile.board.dep, which is processed recursively as part of the dependency +# resolution. +FEATURES_OPTIONAL += netif FEATURES_OPTIONAL += periph_rtc @@ -58,14 +48,5 @@ endif include $(RIOTBASE)/Makefile.include -ifneq (,$(filter $(BOARD),$(BOARD_PROVIDES_NETIF))) - # We use only the lower layers of the GNRC network stack, hence, we can - # reduce the size of the packet buffer a bit - # Set GNRC_PKTBUF_SIZE via CFLAGS if not being set via Kconfig. - ifndef CONFIG_GNRC_PKTBUF_SIZE - CFLAGS += -DCONFIG_GNRC_PKTBUF_SIZE=512 - endif -endif - # Set a custom channel if needed include $(RIOTMAKE)/default-radio-settings.inc.mk diff --git a/examples/default/Makefile.board.dep b/examples/default/Makefile.board.dep new file mode 100644 index 000000000000..ca5f03cba79b --- /dev/null +++ b/examples/default/Makefile.board.dep @@ -0,0 +1,20 @@ +ifneq (,$(filter netif,$(FEATURES_USED))) + # Use modules for networking + # gnrc is a meta module including all required, basic gnrc networking modules + USEMODULE += gnrc + # use the default network interface for the board + USEMODULE += netdev_default + # automatically initialize the network interface + USEMODULE += auto_init_gnrc_netif + # shell command to send L2 packets with a simple string + USEMODULE += gnrc_txtsnd + # the application dumps received packets to stdout + USEMODULE += gnrc_pktdump + + # We use only the lower layers of the GNRC network stack, hence, we can + # reduce the size of the packet buffer a bit + # Set GNRC_PKTBUF_SIZE via CFLAGS if not being set via Kconfig. + ifndef CONFIG_GNRC_PKTBUF_SIZE + CFLAGS += -DCONFIG_GNRC_PKTBUF_SIZE=512 + endif +endif diff --git a/features.yaml b/features.yaml index 2acf51145c8b..ab6c59527397 100644 --- a/features.yaml +++ b/features.yaml @@ -879,6 +879,8 @@ groups: features: - name: ethernet help: The board has Ethernet connectivity + - name: netif + help: The board has a network interface - name: highlevel_stdio help: A high-level stdio method (such as CDC ACM) is used. This requires a running thread and set-up and will not print during a crash. diff --git a/makefiles/features_existing.inc.mk b/makefiles/features_existing.inc.mk index efa9453602cc..57dcc500d209 100644 --- a/makefiles/features_existing.inc.mk +++ b/makefiles/features_existing.inc.mk @@ -132,6 +132,7 @@ FEATURES_EXISTING := \ highlevel_stdio \ libstdcpp \ motor_driver \ + netif \ newlib \ no_idle_thread \ periph_adc \ diff --git a/tests/Makefile.boards.netif b/tests/Makefile.boards.netif deleted file mode 100644 index 036c0f612f0d..000000000000 --- a/tests/Makefile.boards.netif +++ /dev/null @@ -1,63 +0,0 @@ -# Non-exhaustive list of BOARDs providing a net interface, extend as needed -# keeping alfabetical order -BOARD_PROVIDES_NETIF := \ - airfy-beacon \ - arduino-nano-33-ble \ - atmega256rfr2-xpro \ - avr-rss2 \ - b-l072z-lrwan1 \ - calliope-mini \ - cc2538dk \ - derfmega128 \ - derfmega256 \ - dwm1001 \ - esp32-wroom-32 \ - frdm-kw41z \ - generic-cc2538-cc2592-dk \ - hamilton \ - iotlab-a8-m3 \ - iotlab-m3 \ - lobaro-lorabox \ - lora-e5-dev \ - lsn50 \ - microbit \ - microbit-v2 \ - microduino-corerf \ - msba2 \ - mulle \ - native \ - native64 \ - nrf51dk \ - nrf51dongle \ - nrf52840-mdk \ - nrf52840dk \ - nrf52840dongle \ - nrf52dk \ - nrf6310 \ - nucleo-f207zg \ - nucleo-f429zi \ - nucleo-f439zi \ - nucleo-f767zi \ - nucleo-wl55jc \ - openlabs-kw41z-mini \ - openlabs-kw41z-mini-256kib \ - openmote-b \ - openmote-cc2538 \ - pba-d-01-kw2x \ - phynode-kw41z \ - remote-pa \ - remote-reva \ - ruuvitag \ - same54-xpro \ - samr21-xpro \ - samr30-xpro \ - spark-core \ - stm32f746g-disco \ - stm32f7508-dk \ - telosb \ - thingy52 \ - usb-kw41z \ - yunjia-nrf51822 \ - z1 \ - zigduino \ - # diff --git a/tests/net/netstats_l2/Makefile b/tests/net/netstats_l2/Makefile index 91fb7b9066a7..1de383edde13 100644 --- a/tests/net/netstats_l2/Makefile +++ b/tests/net/netstats_l2/Makefile @@ -1,7 +1,6 @@ include ../Makefile.net_common -include $(RIOTBASE)/tests/Makefile.boards.netif -BOARD_WHITELIST += $(BOARD_PROVIDES_NETIF) +FEATURES_REQUIRED += netif USEMODULE += shell USEMODULE += shell_cmds_default diff --git a/tests/pkg/edhoc_c/Makefile b/tests/pkg/edhoc_c/Makefile index bc29f9879893..f9804536abef 100644 --- a/tests/pkg/edhoc_c/Makefile +++ b/tests/pkg/edhoc_c/Makefile @@ -1,7 +1,6 @@ include ../Makefile.pkg_common -include $(RIOTBASE)/tests/Makefile.boards.netif -BOARD_WHITELIST += $(BOARD_PROVIDES_NETIF) +FEATURES_REQUIRED += netif # Cannot run the test on `murdock` in `native` # open(/dev/net/tun): No such file or directory TEST_ON_CI_BLACKLIST += native native64