1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

3343 Commits

Author SHA1 Message Date
Benjamin Valentin
a3adaa7ec0 gnrc_ipv6_nib: fix index calculation
We must divide the pointer difference (in bytes) by the size of
the individual elements to get the index of the element.
2020-03-28 00:00:16 +01:00
Benjamin Valentin
a835ad3e13 gnrc_ipv6_nib: append ext_opts when adding sixco 2020-03-27 22:52:31 +01:00
benpicco
8024380f7b
Merge pull request #13700 from miri64/gnrc_sock/enh/recv_buf
gnrc_sock: provide implementation for `sock_*_recv_buf()`
2020-03-27 16:34:57 +01:00
benpicco
15dc9fe0de
Merge pull request #13731 from benpicco/upstream_no_rtr_adv
gnrc_uhcp, gnrc_dhcpv6_client_6lbr: disable Router Advertisements on upstream interface
2020-03-27 10:32:59 +01:00
Benjamin Valentin
3f24eaefb9 gnrc_uhcp: disable router advertisements on upstream interface 2020-03-27 00:37:54 +01:00
Benjamin Valentin
fec156899c gnrc_dhcpv6_client_6lbr: disable router advertisements on upstream interface
We don't want to advertise ourselves as a router to the upstream router.
This also leads to the border router ignoring advertisements from the upstream
router.
2020-03-27 00:37:54 +01:00
Martine Lenders
f39cfc7556
Merge pull request #13253 from nmeum/pr/random_ephemeral_port
gnrc_sock_udp: choose random ephemeral port
2020-03-26 15:00:14 +01:00
Martine Lenders
061eb88c05
Merge pull request #12994 from jia200x/pr/gnrc_netif_desc_alloc
gnrc_netif: implementation of dynamic GNRC_NETIF_NUMOF approach
2020-03-26 14:30:44 +01:00
Jose Alamos
44f7cb712c gnrc_netif: add GNRC_NETIF_SINGLE macro 2020-03-26 14:19:02 +01:00
Martine Lenders
cba1a2da0c
Merge pull request #13666 from jue89/feature/evtimer_now_msec
net/gnrc/ipv6/nib: remove direct dependency to xtimer
2020-03-26 13:50:13 +01:00
Jose Alamos
e451570219 gnrc_netif: remove GNRC_NETIF_NUMOF macro 2020-03-26 11:12:23 +01:00
Jose Alamos
67ed9defbe gnrc_netif_xxx_create: use external netif allocation 2020-03-26 11:12:23 +01:00
Martine Lenders
ab5deca3b0
Merge pull request #13712 from miri64/gnrc_uhcp/fix/prefix_len
gnrc_uhcp: use actually advertised prefix length
2020-03-25 18:46:00 +01:00
Martine S. Lenders
01d94f268a
gnrc_uhcp: use actually advertised prefix length
This makes the UHCP client to use the actually advertised prefix length
instead of assuming /64.
2020-03-25 16:55:01 +01:00
benpicco
6ae0fd7c82
Merge pull request #13485 from miri64/gnrc_dhcpv6/enh/configure-context
gnrc_dhcpv6_client: configure prefix as compression context on 6LBRs
2020-03-25 16:48:11 +01:00
benpicco
53790d1269
Merge pull request #13713 from miri64/gnrc_sixlowpan_iphc/bug/encode-zero-header
gnrc_sixlowpan_iphc: zero IPv6 header before decompressing into it
2020-03-25 16:43:17 +01:00
4c59e93a35
Merge pull request #13711 from cgundogan/pr/nanocoap/coap_opt_get_opaque/const
nanocoap: add const qualifier to pkt of coap_opt_get_opaque()
2020-03-25 15:21:23 +01:00
Martine S. Lenders
ac222521ab
gnrc_sixlowpan_iphc: zero IPv6 header before decompressing into it 2020-03-25 14:54:18 +01:00
Cenk Gündoğan
5e42e26a6e nanocoap: add const qualifier to pkt of coap_opt_get_opaque() 2020-03-25 13:38:21 +01:00
Martine S. Lenders
4fc0251b4b
gnrc_ipv6_nib: only route to prefix list entry if on-link
In 06aa65e1ba (#10627) a new behavior was
introduced in IPv6 route resolution to try address resolution only at
interfaces that have the prefix of the address to be resolved configured
in the prefix list. This however only makes sense, if the prefix
configured is [on-link], otherwise there is small likelihood of the
address to be resolved being on that link.

For the error case presented for 06aa65e (circular routing at the border
router) this made sense, however within a 6LoWPAN, due to the prefix
being valid for the entire mesh, this leads to the nodes always trying
classic address resolution for in-network addresses instead of just
routing to the default route.
Classic address resolution however fails, as 6LoWPAN hosts typically
[don't join the solicited-node multicast address of their unicast
addresses][6LN-iface-init], resulting in in-network addresses not being
reachable.

As such, to prevent both error cases

- the fallback to address resolution by prefix list must only be used
  when the prefix is on-link,
- the prefix configured by DHCPv6/UHCP at the 6LoWPAN border router
  must be configured as on-link, but
- the prefix must not be advertised as on-link within the 6LoWPAN to
  still be [in line with RFC 6775][RFC-6775-forbidden]

With this change these cases are covered.

[on-link]: https://tools.ietf.org/html/rfc4861#page-6
[RFC 6775]: https://tools.ietf.org/html/rfc6775
[6LN-iface-init]: https://tools.ietf.org/html/rfc6775#section-5.2
[RFC-6775-forbidden]: https://tools.ietf.org/html/rfc6775#section-6.1
2020-03-25 13:13:40 +01:00
Martine Lenders
e47c8fa91c
Merge pull request #10627 from miri64/gnrc_ipv6_nib/fix/forward-to-pl
gnrc_ipv6_nib: don't ignore PL for route
2020-03-24 21:49:56 +01:00
Martine Lenders
06aa65e1ba
gnrc_ipv6_nib: don't ignore PL for route
When pinging to a prefix for which there is a prefix list entry on the
node (so no next hop) but a default route, a packet to a non-existent
address under that prefix results in the packet being forwarded to the
default route instead. This fixes it, so the node tries address
resolution on the interface the prefix list entry is associated to.
2020-03-24 18:19:18 +01:00
Martine S. Lenders
39cd293a0e
gnrc_sock: provide implementation for sock_*_recv_buf() 2020-03-24 17:15:17 +01:00
Juergen Fitschen
877e0a9b32 net/gnrc/ipv6/nib: fix typos 2020-03-24 13:07:20 +01:00
Juergen Fitschen
47f5cd8618 net/gnrc/ipv6/nib: make use of the evtimer system time getter
This commit removes the implication that evtimer uses xtimer as timer backend.
2020-03-24 13:07:20 +01:00
1d5010e126
nanocoap: make separate tree handling function
This refactors nanocoap to seperate out the resource tree parsing. It
allows for calling the tree handler with custom resource trees. The
advantage is that a resource with COAP_MATCH_SUBTREE can parse a new
separate resource tree.
2020-03-23 15:08:53 +01:00
Francisco
cdbf0b2d69
Merge pull request #13583 from benpicco/at86rf215-minimal
drivers/at86rf215: add basic support for AT86RF215 dual-band radio
2020-03-20 09:33:50 +01:00
benpicco
5435792034
Merge pull request #12277 from benemorius/pr/kw41zrf
drivers: add kw41zrf
2020-03-20 00:49:56 +01:00
Joakim Nohlgård
5bd67d88a8 drivers/kw41zrf: Transceiver driver for the KW41Z radio
This is the radio found in NXP Kinetis KW41Z, KW21Z. Only 802.15.4 mode
is implemented (KW41Z also supports BLE on the same transceiver).

The driver uses vendor supplied initialization code for the low level
XCVR hardware, these files were imported from KSDK 2.2.0 (framework_5.3.5)
2020-03-19 17:00:04 -05:00
Benjamin Valentin
d35511bee7 drivers/at86rf215: Add basic driver for the AT86RF215 radio
This adds a driver for the SPI based AT86RF215 transceiver.
The chip supports the IEEE Std 802.15.4-2015 and IEEE Std 802.15.4g-2012 standard.

This driver supports two versions of the chip:
    - AT86RF215:  dual sub-GHz & 2.4 GHz radio & baseband
    - AT86RF215M: sub-GHz radio & baseband only

Both radios support the following PHY modes:
    - MR-FSK
    - MR-OFDM
    - MR-O-QPKS
    - O-QPSK (legacy)

The driver currently only implements support for legacy O-QPSK.

To use both interfaces, add

    GNRC_NETIF_NUMOF := 2

to your Makefile.

The transceiver is able to send frames of up to 2047 bytes according to
IEEE 802.15.4g-2012 when operating in non-legacy mode.

Known issues:

 - [ ] dBm setting values are bogus
 - [ ] Channel spacing for sub-GHz MR-O-QPSK might be wrong
 - [ ] TX/RX stress test will lock up the driver on openmote-b
2020-03-19 14:39:18 +01:00
Jose Alamos
4393822b0f gnrc_netif: add function to check if device requires 6Lo 2020-03-17 10:54:30 +01:00
Jose Alamos
6ace7b5472 gnrc_netif: use gnrc_netif_single where possible 2020-03-17 10:54:30 +01:00
Leandro Lanzieri
d281d4843f
Merge pull request #13628 from jia200x/pr/gnrc_rpl_macro
gnrc_rpl: add default value to GNRC_RPL_DEFAULT_NETIF
2020-03-13 15:47:13 +01:00
Jose Alamos
b553535cea gnrc_rpl_auto_init: replace preprocessor logic with if chain 2020-03-13 13:30:29 +01:00
Ken Bannister
ec2aff4546
Merge pull request #13240 from kb2ma/gcoap/deprecate_add_qstring
net/coap: deprecate gcoap_add_qstring() and update uses
2020-03-13 08:04:50 -04:00
Martine Lenders
20e30ec58b
Merge pull request #13622 from gschorcht/net/dhcpv6_fix_opt_len
sys/net/dhcpv6: fixes option length handling in client implementation
2020-03-12 18:56:43 +01:00
Gunar Schorcht
a25c61bc8b sys/net/dhcpv6: fix client option length handling 2020-03-12 18:33:17 +01:00
benpicco
1212165222
Merge pull request #13584 from kb2ma/nanocoap/add_uquery_improvements
net/nanocoap: add uquery improvements
2020-03-12 15:18:07 +01:00
Ken Bannister
c55837d809 net/nanocoap: add query option directly 2020-03-12 08:44:26 -04:00
Martine S. Lenders
411e320b0c
sock_async_event: update for async callback argument support 2020-03-11 16:54:12 +01:00
Martine S. Lenders
4bdd138021
gnrc_sock: update implementation for async callback argument 2020-03-11 16:54:11 +01:00
Martine S. Lenders
612e782b3c
sock_async: supply optional callback argument with callback setter 2020-03-11 16:54:11 +01:00
Martine S. Lenders
6e6e435c65
sock_async: add optional callback argument 2020-03-11 16:54:11 +01:00
José Alamos
de4a1bf552
Merge pull request #13595 from gschorcht/gnrc/lorawan/fix_downlink_handling
gnrc/lorawan: fixes the handling of downlink frames without payload
2020-03-09 15:08:25 +01:00
Martine S. Lenders
c110337f6a
gnrc_dhcpv6_client: only configure 6Lo-ND features if interface is 6LN 2020-03-09 14:21:53 +01:00
Martine S. Lenders
06d1d79ffa
gnrc_dhcpv6_client: configure prefix as compression context on 6LBRs 2020-03-09 14:21:53 +01:00
Martine S. Lenders
079b9f717f
gnrc_dhcpv6_client: replace #if guards with if expressions 2020-03-09 14:21:52 +01:00
Gunar Schorcht
de38fc5e2e gnrc/lorawan: fix handling of downlink message without payload 2020-03-09 12:33:03 +01:00
Gunar Schorcht
32c78e3317 gnrc/lorawan: fix netopt_state_t size in link_layer
`netopt_state_t` is an enumeration type which is not necessarily 1 byte. If `uint8_t` is used, the cast `*((const netopt_state_t*) val` in `sx127x_netdev::_set`tries to read the real size, which can be more than the given length of 1 byte. Therefore, `netstat_opt_t` has to be used instead of `uint8_t`
2020-03-08 17:10:24 +01:00
Martine Lenders
c30f83ac3b
Merge pull request #13579 from jia200x/pr/gnrc_netif_send
gnrc_netif_send: add send function
2020-03-06 20:07:45 +01:00