nib.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2017 Freie Universit├Ąt Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
25 #ifndef NET_GNRC_IPV6_NIB_H
26 #define NET_GNRC_IPV6_NIB_H
27 
28 #include "net/gnrc/ipv6/nib/abr.h"
29 #include "net/gnrc/ipv6/nib/ft.h"
30 #include "net/gnrc/ipv6/nib/nc.h"
31 #include "net/gnrc/ipv6/nib/pl.h"
32 
33 #include "net/icmpv6.h"
34 #include "net/ipv6/addr.h"
35 #include "net/ipv6/hdr.h"
36 #include "net/gnrc/ipv6/nib/nc.h"
37 #include "net/gnrc/netif.h"
38 #include "net/gnrc/pkt.h"
39 
40 #ifdef __cplusplus
41 extern "C" {
42 #endif
43 
57 #define GNRC_IPV6_NIB_SND_UC_NS (0x4fc0U)
58 
68 #define GNRC_IPV6_NIB_SND_MC_NS (0x4fc1U)
69 
78 #define GNRC_IPV6_NIB_SND_NA (0x4fc2U)
79 
88 #define GNRC_IPV6_NIB_SEARCH_RTR (0x4fc3U)
89 
100 #define GNRC_IPV6_NIB_REPLY_RS (0x4fc5U)
101 
112 #define GNRC_IPV6_NIB_SND_MC_RA (0x4fc6U)
113 
123 #define GNRC_IPV6_NIB_REACH_TIMEOUT (0x4fc7U)
124 
134 #define GNRC_IPV6_NIB_DELAY_TIMEOUT (0x4fc8U)
135 
145 #define GNRC_IPV6_NIB_ADDR_REG_TIMEOUT (0x4fc9U)
146 
156 #define GNRC_IPV6_NIB_ABR_TIMEOUT (0x4fcbU)
157 
164 #define GNRC_IPV6_NIB_PFX_TIMEOUT (0x4fccU)
165 
172 #define GNRC_IPV6_NIB_RTR_TIMEOUT (0x4fcdU)
173 
183 #define GNRC_IPV6_NIB_RECALC_REACH_TIME (0x4fceU)
184 
194 #define GNRC_IPV6_NIB_REREG_ADDRESS (0x4fcfU)
195 
204 #define GNRC_IPV6_NIB_ROUTE_TIMEOUT (0x4fd0U)
205 
214 #define GNRC_IPV6_NIB_DAD (0x4fd1U)
215 
224 #define GNRC_IPV6_NIB_VALID_ADDR (0x4fd2U)
225 
231 enum {
245 
257 
278 };
279 
283 void gnrc_ipv6_nib_init(void);
284 
293 
316  gnrc_netif_t *netif, gnrc_pktsnip_t *pkt,
317  gnrc_ipv6_nib_nc_t *nce);
318 
359 void gnrc_ipv6_nib_handle_pkt(gnrc_netif_t *netif, const ipv6_hdr_t *ipv6,
360  const icmpv6_hdr_t *icmpv6, size_t icmpv6_len);
361 
369 void gnrc_ipv6_nib_handle_timer_event(void *ctx, uint16_t type);
370 
371 #if GNRC_IPV6_NIB_CONF_ROUTER || defined(DOXYGEN)
372 
381 void gnrc_ipv6_nib_change_rtr_adv_iface(gnrc_netif_t *netif, bool enable);
382 #else
383 
386 #define gnrc_ipv6_nib_change_rtr_adv_iface(netif, enable) \
387  (void)netif; (void)enable
388 #endif
389 
390 #ifdef __cplusplus
391 }
392 #endif
393 
394 #endif /* NET_GNRC_IPV6_NIB_H */
395 
int gnrc_ipv6_nib_get_next_hop_l2addr(const ipv6_addr_t *dst, gnrc_netif_t *netif, gnrc_pktsnip_t *pkt, gnrc_ipv6_nib_nc_t *nce)
Gets link-layer address of next hop to a destination address.
Definitions for IPv6 addresses.
General definitions for network packets and their helper functions.
Forwarding table definitions.
neighbor state change
Definition: nib.h:277
Data type to represent an IPv6 packet header.
Definition: ipv6/hdr.h:66
void gnrc_ipv6_nib_handle_timer_event(void *ctx, uint16_t type)
Handles a timer event.
Neighbor cache entry view on NIB.
Definition: nc.h:142
void gnrc_ipv6_nib_init(void)
Initialize NIB.
Prefix list defintions.
Neighbor cache definitions.
void gnrc_ipv6_nib_change_rtr_adv_iface(gnrc_netif_t *netif, bool enable)
Changes the state if an interface advertises itself as a router or not.
IPv6 header type and helper function definitions.
reactive routing query
Definition: nib.h:244
void gnrc_ipv6_nib_handle_pkt(gnrc_netif_t *netif, const ipv6_hdr_t *ipv6, const icmpv6_hdr_t *icmpv6, size_t icmpv6_len)
Handles a received ICMPv6 packet.
Representation of a network interface.
Definition: gnrc/netif.h:62
Definition for GNRC's network interfaces.
Authoritative border router list definitions.
General ICMPv6 message format.
Definition: icmpv6.h:141
ICMPv6 type and function definitions.
Type to represent parts (either headers or payload) of a packet, called snips.
Data type to represent an IPv6 address.
Definition: ipv6/addr.h:74
route notification
Definition: nib.h:256
void gnrc_ipv6_nib_init_iface(gnrc_netif_t *netif)
Adds an interface to be managed by the NIB.