flags.h
4.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
/*
* Copyright (C) 2017 Freie Universität Berlin
*
* This file is subject to the terms and conditions of the GNU Lesser
* General Public License v2.1. See the file LICENSE in the top level
* directory for more details.
*/
/**
* @ingroup net_gnrc_netif2
* @{
*
* @file
* @brief Flag definitions for @ref net_gnrc_netif2
*
* @author Martine Lenders <m.lenders@fu-berlin.de>
*/
#ifndef NET_GNRC_NETIF2_FLAGS_H
#define NET_GNRC_NETIF2_FLAGS_H
#ifdef __cplusplus
extern "C" {
#endif
/**
* @brief Auto-address configuration modes
* @anchor net_gnrc_netif2_aac
*/
enum {
GNRC_NETIF2_AAC_NONE = 0, /**< no configuration */
GNRC_NETIF2_AAC_AUTO, /**< Use some automatic bootstrapping (e.g. SLAAC with IPv6) */
GNRC_NETIF2_AAC_DHCP, /**< Use DHCP(v6) */
/* extend if needed */
};
/**
* @name Network interface flags
* @anchor net_gnrc_netif2_flags
* @{
*/
/**
* @brief Network interface has link-layer address
*
* There are link-layers (e.g. SLIP) that do not have (nor require) link-layer
* addresses. This flag signifies this fact to upper layers by leaving it unset.
*/
#define GNRC_NETIF2_FLAGS_HAS_L2ADDR (0x00000001U)
/**
* @brief Network interface is enabled for IPv6 forwarding
*/
#define GNRC_NETIF2_FLAGS_IPV6_FORWARDING (0x00000002U)
/**
* @brief Network interface advertises itself as an IPv6 router
* (implies @ref GNRC_NETIF2_FLAGS_IPV6_FORWARDING to be set)
*/
#define GNRC_NETIF2_FLAGS_IPV6_RTR_ADV (0x00000004U)
/**
* @brief This interface advertises its gnrc_netif2_t::mtu to other nodes
* (implies @ref GNRC_NETIF2_FLAGS_IPV6_RTR_ADV to be set)
*/
#define GNRC_NETIF2_FLAGS_IPV6_ADV_MTU (0x00000008U)
/**
* @brief This interface advertises its gnrc_netif2_t::cur_hl to other nodes
* (implies @ref GNRC_NETIF2_FLAGS_IPV6_RTR_ADV to be set)
*/
#define GNRC_NETIF2_FLAGS_IPV6_ADV_CUR_HL (0x00000010U)
/**
* @brief This interface advertises its reachable time to other nodes
* (implies @ref GNRC_NETIF2_FLAGS_IPV6_RTR_ADV to be set)
*/
#define GNRC_NETIF2_FLAGS_IPV6_ADV_REACH_TIME (0x00000020U)
/**
* @brief This interface advertises its retransmission timer to other nodes
* (implies @ref GNRC_NETIF2_FLAGS_IPV6_RTR_ADV to be set)
*/
#define GNRC_NETIF2_FLAGS_IPV6_ADV_RETRANS_TIMER (0x00000040U)
/**
* @brief If gnrc_netif2_t::ipv6::aac_mode == GNRC_NETIF2_AAC_DHCP then this
* flag indicates that other configuration information is available via
* DHCPv6 (e.g. DNS-related information)
*
* @see [RFC 4861, section 4.2](https://tools.ietf.org/html/rfc4861#section-4.2)
*/
#define GNRC_NETIF2_FLAGS_IPV6_ADV_O_FLAG (0x00000080U)
/**
* @brief This interface uses 6Lo header compression
*
* @see [RFC 6282](https://tools.ietf.org/html/rfc6282)
*/
#define GNRC_NETIF2_FLAGS_6LO_HC (0x00000100U)
/**
* @brief This interface acts as a 6Lo border router to the LLN
*/
#define GNRC_NETIF2_FLAGS_6LO_ABR (0x00000200U)
/**
* @brief This interface acts as a mesh-under node (route-over topology when
* unset)
*/
#define GNRC_NETIF2_FLAGS_6LO_MESH (0x00000400U)
/**
* @brief Interface supports 6LoWPAN general header compression
*
* @attention 6CIO (which propagates this flag throughout) not implemented yet
* @see [RFC 7400, section 3.3](https://tools.ietf.org/html/rfc7400#section-3.3)
* @see [draft-ietf-6lo-rfc6775-update-09, section 6.3]
* (https://tools.ietf.org/html/draft-ietf-6lo-rfc6775-update-09#section-6.3)
*/
#define GNRC_NETIF2_FLAGS_6LO_BACKBONE (0x00000800U)
/**
* @brief Marks if the addresses of the interface were already registered
* to an interface or not
*/
#define GNRC_NETIF2_FLAGS_6LO_ADDRS_REG (0x00001000U)
/**
* @brief Mask for @ref gnrc_mac_tx_feedback_t
*/
#define GNRC_NETIF2_FLAGS_MAC_TX_FEEDBACK_MASK (0x00006000U)
/**
* @brief Flag to track if a transmission might have corrupted a received
* packet
*/
#define GNRC_NETIF2_FLAGS_MAC_RX_STARTED (0x00008000U)
/** @} */
#ifdef __cplusplus
}
#endif
#endif /* NET_GNRC_NETIF2_FLAGS_H */
/** @} */