Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make: introduce netdev_default pseudomodule #5134

Merged
merged 1 commit into from
Mar 24, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 25 additions & 4 deletions Makefile.dep
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,33 @@ ifneq (,$(filter nhdp,$(USEMODULE)))
USEMODULE += oonf_rfc5444
endif

ifneq (,$(filter gnrc_netdev_default,$(USEMODULE)))
USEMODULE += gnrc_netif
USEMODULE += netdev_default
endif

ifneq (,$(filter cc110x,$(USEMODULE)))
ifneq (,$(filter gnrc_netdev_default,$(USEMODULE)))
USEMODULE += gnrc_cc110x
# XXX: this can be modelled as a dependency for gnrc_netdev_default as soon
# as all drivers are ported to netdev2
USEMODULE += gnrc_netdev2
endif
endif

ifneq (,$(filter kw2xrf,$(USEMODULE)))
ifneq (,$(filter gnrc_netdev_default,$(USEMODULE)))
USEMODULE += gnrc_nomac
endif
endif

ifneq (,$(filter at86rf2%,$(USEMODULE)))
USEMODULE += netdev2_ieee802154
ifneq (,$(filter gnrc_netdev_default,$(USEMODULE)))
# XXX: this can be modelled as a dependency for gnrc_netdev_default as soon
# as all drivers are ported to netdev2
USEMODULE += gnrc_netdev2
endif
endif

ifneq (,$(filter netdev2_ieee802154,$(USEMODULE)))
Expand All @@ -32,10 +57,6 @@ ifneq (,$(filter gnrc_conn_udp,$(USEMODULE)))
USEMODULE += gnrc_udp
endif

ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
USEMODULE += gnrc_netif
endif

ifneq (,$(filter netdev2_tap,$(USEMODULE)))
USEMODULE += netif
USEMODULE += netdev2_eth
Expand Down
3 changes: 2 additions & 1 deletion Makefile.pseudomodules
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ PSEUDOMODULES += conn
PSEUDOMODULES += conn_ip
PSEUDOMODULES += conn_tcp
PSEUDOMODULES += conn_udp
PSEUDOMODULES += gnrc_netif_default
PSEUDOMODULES += gnrc_netdev_default
PSEUDOMODULES += gnrc_ipv6_default
PSEUDOMODULES += gnrc_ipv6_router
PSEUDOMODULES += gnrc_ipv6_router_default
Expand All @@ -16,6 +16,7 @@ PSEUDOMODULES += gnrc_sixlowpan_iphc_nhc
PSEUDOMODULES += gnrc_pktbuf
PSEUDOMODULES += log
PSEUDOMODULES += log_printfnoformat
PSEUDOMODULES += netdev_default
PSEUDOMODULES += newlib
PSEUDOMODULES += newlib_nano
PSEUDOMODULES += pktqueue
Expand Down
3 changes: 1 addition & 2 deletions boards/fox/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
ifneq (,$(filter netdev_default gnrc_netdev_default,$(USEMODULE)))
USEMODULE += at86rf231
USEMODULE += gnrc_netdev2
endif

ifneq (,$(filter saul_default,$(USEMODULE)))
Expand Down
3 changes: 1 addition & 2 deletions boards/iotlab-m3/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
ifneq (,$(filter netdev_default gnrc_netdev_default,$(USEMODULE)))
USEMODULE += at86rf231
USEMODULE += gnrc_netdev2
endif

ifneq (,$(filter saul_default,$(USEMODULE)))
Expand Down
4 changes: 2 additions & 2 deletions boards/msba2/Makefile.include
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
USEMODULE += cc110x gnrc_netdev2 gnrc_cc110x
ifneq (,$(filter netdev_default gnrc_netdev_default,$(USEMODULE)))
USEMODULE += cc110x
endif

USEMODULE += msba2-common
Expand Down
3 changes: 1 addition & 2 deletions boards/mulle/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
ifneq (,$(filter netdev_default gnrc_netdev_default,$(USEMODULE)))
USEMODULE += at86rf212b
USEMODULE += gnrc_netdev2
endif

ifneq (,$(filter saul_default,$(USEMODULE)))
Expand Down
3 changes: 1 addition & 2 deletions boards/native/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
ifneq (,$(filter netdev_default gnrc_netdev_default,$(USEMODULE)))
USEMODULE += netdev2_tap
USEMODULE += gnrc_netdev2
endif
3 changes: 1 addition & 2 deletions boards/pba-d-01-kw2x/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
ifneq (,$(filter netdev_default gnrc_netdev_default,$(USEMODULE)))
USEMODULE += kw2xrf
USEMODULE += gnrc_nomac
endif

ifneq (,$(filter saul_default,$(USEMODULE)))
Expand Down
3 changes: 1 addition & 2 deletions boards/samr21-xpro/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
ifneq (,$(filter gnrc_netif_default,$(USEMODULE)))
ifneq (,$(filter gnrc_netdev_default netdev_default,$(USEMODULE)))
USEMODULE += at86rf233
USEMODULE += gnrc_netdev2
endif

ifneq (,$(filter saul_default,$(USEMODULE)))
Expand Down
2 changes: 1 addition & 1 deletion cpu/native/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ module, you need to specify a network interface like this:
make term PORT=tap0

**Please note:** in case you're using RIOT's default network stack, the GNRC
stack, you may also use `gnrc_netif_default` module and also add
stack, you may also use `gnrc_netdev_default` module and also add
`auto_init_gnrc_netif` in order to automatically initialize the interface.


Expand Down
2 changes: 1 addition & 1 deletion examples/ccn-lite-relay/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ USEMODULE += shell
USEMODULE += shell_commands
# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
USEMODULE += timex
USEMODULE += xtimer
Expand Down
2 changes: 1 addition & 1 deletion examples/default/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ ifneq (,$(filter $(BOARD),$(BOARD_PROVIDES_NETIF)))
# gnrc is a meta module including all required, basic gnrc networking modules
USEMODULE += gnrc
# use the default network interface for the board
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
# automatically initialize the network interface
USEMODULE += auto_init_gnrc_netif
# the application dumps received packets to stdout
Expand Down
2 changes: 1 addition & 1 deletion examples/gnrc_border_router/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ CFLAGS += -DSLIP_BAUDRATE=$(SLIP_BAUDRATE)

# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
# Include SLIP package for IP over Serial communication
USEMODULE += gnrc_slip
Expand Down
2 changes: 1 addition & 1 deletion examples/gnrc_minimal/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ BOARD_INSUFFICIENT_MEMORY := chronos msb-430 msb-430h

# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
# Specify the minimum networking modules for IPv6
USEMODULE += gnrc_ipv6
Expand Down
2 changes: 1 addition & 1 deletion examples/gnrc_networking/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ BOARD_INSUFFICIENT_MEMORY := airfy-beacon chronos msb-430 msb-430h nrf51dongle \

# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
# Specify the mandatory networking modules for IPv6 and UDP
USEMODULE += gnrc_ipv6_router_default
Expand Down
2 changes: 1 addition & 1 deletion examples/gnrc_tftp/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ BOARD_INSUFFICIENT_MEMORY := airfy-beacon chronos msb-430 msb-430h nrf51dongle \

# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
# Specify the mandatory networking modules for IPv6 and UDP
USEMODULE += gnrc_ipv6_router_default
Expand Down
2 changes: 1 addition & 1 deletion examples/microcoap_server/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ BOARD_INSUFFICIENT_MEMORY := airfy-beacon chronos msb-430 msb-430h nrf51dongle \

# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
# Specify the mandatory networking modules for IPv6 and UDP
USEMODULE += gnrc_ipv6_router_default
Expand Down
2 changes: 1 addition & 1 deletion examples/posix_sockets/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ BOARD_INSUFFICIENT_MEMORY := airfy-beacon chronos msb-430 msb-430h nrf51dongle n

# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
# Specify the mandatory networking modules for socket communication via UDP
USEMODULE += gnrc_ipv6_default
Expand Down
2 changes: 1 addition & 1 deletion sys/include/net/gnrc.h
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@
*
* - To include the default network device(s) on your board:
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ {.mk}
* USEMODULE += gnrc_netif_default
* USEMODULE += gnrc_netdev_default
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*
* - To auto-initialize these network devices as GNRC network interfaces
Expand Down
2 changes: 1 addition & 1 deletion tests/conn_ip/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ RIOTBASE ?= $(CURDIR)/../..
BOARD_INSUFFICIENT_MEMORY := chronos msb-430 msb-430h nucleo-f334 stm32f0discovery telosb \
weio wsn430-v1_3b wsn430-v1_4 z1

USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
USEMODULE += gnrc_icmpv6_echo
USEMODULE += gnrc_ipv6_default
Expand Down
2 changes: 1 addition & 1 deletion tests/driver_enc28j60/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ FEATURES_REQUIRED = periph_spi periph_gpio
BOARD_INSUFFICIENT_MEMORY := msb-430h nucleo-f334 stm32f0discovery weio z1

USEMODULE += gnrc_netdev2
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
USEMODULE += enc28j60
USEMODULE += gnrc_ipv6_router_default
Expand Down
2 changes: 1 addition & 1 deletion tests/gnrc_ipv6_ext/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ BOARD_INSUFFICIENT_MEMORY := airfy-beacon chronos msb-430 msb-430h nrf51dongle \

# Include packages that pull up and auto-init the link layer.
# NOTE: 6LoWPAN will be included if IEEE802.15.4 devices are present
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
# Specify the mandatory networking modules for IPv6
USEMODULE += gnrc_ipv6_router_default
Expand Down
4 changes: 2 additions & 2 deletions tests/zep/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ include ../Makefile.tests_common
BOARD_WHITELIST = native

USEMODULE += gnrc_zep
USEMODULE += gnrc_netif_default
USEMODULE += gnrc_netdev_default
USEMODULE += auto_init_gnrc_netif
USEMODULE += gnrc_ipv6_default
USEMODULE += gnrc_nomac
Expand All @@ -25,7 +25,7 @@ CFLAGS += -DZEP_DST="\"$(ZEP_DST)\""
CFLAGS += -DZEP_SRC_PORT=$(ZEP_SRC_PORT)
CFLAGS += -DZEP_DST_PORT=$(ZEP_DST_PORT)

# one for gnrc_netif_default and one for ZEP
# one for gnrc_netdev_default and one for ZEP
CFLAGS += -DGNRC_NETIF_NUMOF=2

include $(RIOTBASE)/Makefile.include