1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-26 06:53:52 +01:00

5088 Commits

Author SHA1 Message Date
Elena Frank
19a4ba04d1 gnrc/netapi: add notify message API
The netapi notify API enables protocol-independent, cross-layer
notification events.
Lower layers in the network stack can use this to inform upper
layers of network events.
2025-12-09 16:03:59 +01:00
benpicco
ff6b703628
Merge pull request #20900 from maribu/sys/net/nanocoap/transport-agnostic-api
sys/net/*coap: Make APIs (more) transport agnostic
2025-12-08 13:21:42 +00:00
Nils Bernsdorf
8af2f50a7d
gnrc_ipv6_ext_frag: disregard empty fragments 2025-12-05 18:44:58 +01:00
Nils Bernsdorf
d64dcbb71f
gnrc_ipv6_ext_frag: fail on first fragment buffer is too small
This case can happen if a second, but larger first fragment is send
after a smaller.
2025-12-05 18:32:30 +01:00
crasbe
7d5e943dbf
Merge pull request #21855 from Lukas-Luger/pr/legacy-tx_sync
sys/net/gnrc/netif: hold packets after tx_sync split
2025-11-17 08:27:03 +00:00
Lukas-Luger
bae016a157 sys/net/gnrc/netif: fix tx_sync by holding after split 2025-11-17 09:03:28 +01:00
Marian Buschsieweke
ebcb978c23
sys/net/CoRD: update use of deprecated nanocoap APIs 2025-11-10 17:28:43 +01:00
Marian Buschsieweke
4de5e9f413
sys/net/gcoap_dns: update use of deprecated nanocoap APIs 2025-11-10 17:28:43 +01:00
Marian Buschsieweke
9b18061719
sys/net/gcoap_forward_proxy: update users of deprecated nanocoap APIs 2025-11-10 17:28:43 +01:00
Marian Buschsieweke
5b3d111237
sys/net/gcoap: update users of deprecated nanocoap APIs 2025-11-10 17:28:43 +01:00
Marian Buschsieweke
5387c20dde
sys/net/nanocoap: Make APIs (more) transport agnostic
This changes the API of nanocoap with the goal to reduce the expose of
UDP specifics in the API. The plan is to eventually support transports
such as CoAP over TCP and CoAP over WebSocket directly in nanocoap
while sharing most of the code, as e.g. the CoAP Option processing
remains identical. Specifically, the plan is to unlock a transport with
modules and introduce overhead for dispatching to specific transport
only when multiple transports are actually in use.

Support for OSCORE directly in nanocoap is probably not sensible, as
the serialization is very much unlike the other transports. A unified
CoAP API for multiple transports including OSCORE is probably best
implemented on top. But when limited to the boring set of CoAP
transports, we probably can support them well with nanocoap with less
overhead.

Breaking API Changes:
=====================

- `coap_parse()` now returns `ssize_t` instead of `int`
    - This function is not really user facing, so the impact should
      be limited
    - This is useful for stream transports where the buffer may
      contain data of more than one packet. The return value contains
      the number of bytes actually consumed, which will match the
      buffer size for non-stream transports.

API Changes:
============

- `coap_pkt_t` now contains a `uint8_t *buf` pointer instead of a
  `coap_hdr_t *hdr` pointer to the beginning of the buffer
    - This will also work when the buffer is used by non-UDP
      transports
    - A deprecated `coap_udp_hdr_t *hdr` has been crammed into
      an unnamed `union` with `uint8_t *buf`. For architectures
      where pointers have the same memory layout regardless of type
      (e.g. all of the supported ones), this will make `hdr` an
      alias for `buf`.
    - The alias will only be provided if no transport besides UDP is
      used in nanocoap. So existing apps will continue to work, new
      apps that want to support other transports need to move to
      adapt.
- `coap_hdr_t` has been renamed to `coap_udp_hdr_t`
    - A deprecated alias was created for deprecation
- `coap_hdr*()` functions have been deprecated
    - Equivalent `coap_pkt*()` functions have been created that work
      on `coap_pkt_t *` instead of `coap_hdr_t *`
    - If non-UDP transports are used, the deprecated `coap_hdr*()`
      will probably not be exposed to avoid footguns.
- `coap_build_hdr()` has been renamed to `coap_build_udp_hdr()` and
  that works on an `uint8_t *` buffer with a given length, rather than
  on a `coap_hdr_t *` with a *figers crossed* length
    - a deprecated `coap_build_hdr()` function was added that calls
      to `coap_build_udp_hdr()` and has the same signature, so that
      users have time to update
2025-11-10 17:28:41 +01:00
Marvin Drescher
78068728b9 gnrc/lorawan: define gnrc_lorawan_mlme_indication as weak function 2025-11-06 10:02:33 +01:00
Marvin Drescher
0c5e2abe4a gnrc/lorawan: define gnrc_lorawan_mcps_confirm as weak function 2025-11-06 10:01:56 +01:00
benpicco
0995c466c6
Merge pull request #21786 from fabian18/pr/fix_nrf52_after_soft_ack
cpu/nrf52/radio/nrf802154: fix radio after soft ACK
2025-10-31 10:19:54 +00:00
Elena Frank
523d70e7a7 gnrc/rpl/control_messages: handle DIO of different DODAG 2025-10-22 21:34:41 +02:00
Elena Frank
0081a6e99e gnrc/rpl/control_messages: use ipv6_addr_equal to cmp addrs 2025-10-22 21:34:41 +02:00
Elena Frank
ba1895cb20 gnrc/rpl/dodag: add gnrc_rpl_dodag_remove 2025-10-22 21:34:41 +02:00
Elena Frank
b025edc726 gnrc/rpl/dodag: ret void for gnrc_rpl_instance_remove
`gnrc_rpl_instance_remove` can't fail, so it was already always
returning `true`.
2025-10-22 21:34:41 +02:00
Elena Frank
5139847376 gnrc/rpl/of0: compare dodags 2025-10-22 21:34:37 +02:00
Fabian Hüßler
2a32d82045 ieee802154/submac: wait SIFS period for soft ACK 2025-10-22 20:10:10 +02:00
fabian18
e3fa62f38f
Merge pull request #21533 from fabian18/pr/submac_ack_transmission
ieee802154/submac: add automatic ACK transmission when AUTO_ACK is not supported by driver
2025-10-06 11:05:40 +00:00
Teufelchen
0d5e3f056a
Merge pull request #21397 from benpicco/hostnames
net/hosts: add module for static hostname definitions
2025-10-06 09:29:28 +00:00
Fabian Hüßler
4e0f52fc6e drivers/netdev_ieee802154_submac: add transmission of ACK 2025-10-05 21:43:41 +02:00
mguetschow
2d9ccce392
Merge pull request #21577 from elenaf9/gnrc/rpl/refactor-ctrl-messages
gnrc/rpl/control_messages: refactor `gnrc_rpl_recv_DIO`
2025-10-02 08:03:29 +00:00
Benjamin Valentin
c826d0cddb sys/net/sock_util: make unconditional use of dns_query() 2025-09-11 20:05:20 +02:00
Benjamin Valentin
839b75df77 net/util: make unconditional use of dns_query() 2025-09-11 20:05:20 +02:00
Benjamin Valentin
48273ef736 net/hosts: add module for static hostname definitions 2025-09-11 19:16:03 +02:00
Elena Frank
bb04bc17a8 gnrc/netif: small doc improvement 2025-09-09 15:49:29 +02:00
Elena Frank
861a05ec27 gnrc/netif: don't re-append tx_sync snip if tx is done
If sending is blocking or sending failed, the pkt is freed in the call
to `_tx_done`. Thus, the previously split of `tx_sync` snip shouldn't be
re-appended to the already freed pkt.
Similarily, the `GNRC_NETIF_FLAGS_TX_FROM_PKTQUEUE` shouldn't be set in
that case.
2025-09-09 15:21:52 +02:00
Elena Frank
a461e5c41d gnrc/rpl/control_messages: doc gnrc_rpl_recv_DIO 2025-09-05 15:33:35 +02:00
Elena Frank
947141db46 gnrc/rpl/control_messages: _ip_addr_str fn 2025-09-05 15:33:35 +02:00
Elena Frank
f618e59e63 gnrc/rpl/control_messages: extract update_dodag_from_DIO
Extract commit logic from `_recv_DIO_for_{existing,new}_dodag` into new
function `_update_dodag_from_DIO`. The function updates the dodag and
parent based on the DIO data.
2025-09-05 15:33:35 +02:00
Elena Frank
ca2f13fa20 gnrc/rpl/control_messages: extract DIO opts parsing 2025-09-05 15:33:35 +02:00
Elena Frank
b80176333a gnrc/rpl/control_messages: rearrange minor parts 2025-09-05 14:40:19 +02:00
Elena Frank
0879645c2e gnrc/rpl/control_messages: extract _recv_DIO_for_new_dodag 2025-09-05 14:40:19 +02:00
Elena Frank
c5b0c051e5 gnrc/rpl/control_messages: extract _recv_DIO_for_existing_dodag 2025-09-05 14:40:19 +02:00
crasbe
7e7af30de9
Merge pull request #21256 from benpicco/sys/net/gnrc-fixes
gnrc/ipv6/nib: improve debug output, declutter code
2025-09-04 14:44:07 +00:00
crasbe
7c44b06e5c
Merge pull request #21652 from benpicco/nanocoap_server/buf
nanocoap_server: use zero-copy network buffer for parsing request
2025-09-04 14:43:05 +00:00
Marian Buschsieweke
c0cc617c7f
Merge pull request #21633 from crasbe/pr/sntp
sys/net/sntp: migrate from xtimer to ztimer
2025-08-21 16:23:56 +00:00
crasbe
8ab9956ae5 sys/net/sntp: migrate from xtimer to ztimer 2025-08-21 14:27:28 +02:00
Fabian Hüßler
f7b86d703f ieee802154/submac: add some DEBUG() 2025-08-18 12:36:55 +02:00
Benjamin Valentin
ec00a16c57 nanocoap: ensure pkt->hdr equals rbuf in coap_build_reply() 2025-08-07 17:27:39 +02:00
Benjamin Valentin
d48eaf15aa nanocoap_server: use zero-copy network buffer for parsing request 2025-08-07 17:26:57 +02:00
benpicco
4f9f755f99
Merge pull request #20197 from benpicco/coap_iterate_uri_query
nanocoap: add coap_iterate_uri_query()
2025-07-24 11:35:51 +00:00
benpicco
cdfdd215f4
Merge pull request #21454 from benpicco/gnrc_ipv6_nib_get_next_hop_l2addr-cleanup
gnrc/ipv6/nib: clean up `gnrc_ipv6_nib_get_next_hop_l2addr()`
2025-07-24 11:35:14 +00:00
Benjamin Valentin
824d3ea71d nanocoap: add coap_iterate_uri_query() 2025-07-24 13:18:06 +02:00
Marian Buschsieweke
091acb39f6
Merge pull request #21002 from benpicco/netstats_nb-new_api
gnrc_netif: fix neighbor statistics with netdev_new_api
2025-07-23 16:14:32 +00:00
crasbe
d271fc88a4
Merge pull request #21617 from Teufelchen1/deprecate/gnrc_mac
net/mac: Remove deprecated 802.15.4 MAC module
2025-07-21 20:45:24 +00:00
Teufelchen1
944eb05727 net/mac: Remove deprecated 802.15.4 module 2025-07-21 12:57:15 +02:00
Teufelchen
1c1bbf324b
Merge pull request #21585 from elenaf9/rpl/fix-local-repair
gnrc/rpl: check old rank before removing parents
2025-07-21 08:12:31 +00:00