From 80ff517eba8ef701b56752e87210d974b1afb16a Mon Sep 17 00:00:00 2001 From: "Martine S. Lenders" Date: Fri, 27 Sep 2019 12:10:47 +0200 Subject: [PATCH] gnrc_netif: 6lo.h: add flags to indicate SRF capability --- sys/include/net/gnrc/netif/6lo.h | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/sys/include/net/gnrc/netif/6lo.h b/sys/include/net/gnrc/netif/6lo.h index 2c8b57b009..766d1b5ac3 100644 --- a/sys/include/net/gnrc/netif/6lo.h +++ b/sys/include/net/gnrc/netif/6lo.h @@ -18,12 +18,34 @@ #ifndef NET_GNRC_NETIF_6LO_H #define NET_GNRC_NETIF_6LO_H +#include #include #ifdef __cplusplus extern "C" { #endif +/** + * @name Local 6LoWPAN capability flags + * @anchor net_gnrc_netif_6lo_local_flags + * @see gnrc_netif_6lo_t::local_flags + * + * Like the the capability flags in the [6LoWPAN Capability Indication Option + * (6CIO)](https://tools.ietf.org/html/rfc7400#section-3.3) are less about + * hardware capabilities than about the implementation status within the + * network. For the flags in this group it is currently undefined how to + * exchange the capabilities between nodes, but they might be added to the 6CIO + * at a later point. Once the 6CIO is implemented in GNRC and the flag is + * supported by it, the corresponding flag in these local flags can be removed. + * @{ + */ +/** + * @brief Selective Fragment Recovery enabled + * @see [RFC 8931](https://tools.ietf.org/html/rfc8931) + */ +#define GNRC_NETIF_6LO_LOCAL_FLAGS_SFR (0x01) +/** @} */ + /** * @brief 6Lo component of @ref gnrc_netif_t */ @@ -35,6 +57,15 @@ typedef struct { * @ref net_gnrc_sixlowpan_frag "gnrc_sixlowpan_frag". */ uint16_t max_frag_size; + /** + * @brief 6LoWPAN capability flags beyond the ones advertised in + * [6LoWPAN Capability Indication Option + * (6CIO)](https://tools.ietf.org/html/rfc7400#section-3.3) + * + * @see [Local 6LoWPAN capability flags](@ref + * net_gnrc_netif_6lo_local_flags) + */ + uint8_t local_flags; } gnrc_netif_6lo_t; #ifdef __cplusplus