Merge pull request #1063 from simonduq/configure-na

Default NDP configuration
This commit is contained in:
Simon Duquennoy 2015-10-18 20:26:55 +02:00
commit 9c15d1c42f
7 changed files with 24 additions and 4 deletions

View File

@ -192,10 +192,24 @@
#define NBR_TABLE_CONF_MAX_NEIGHBORS 8
#endif /* NBR_TABLE_CONF_MAX_NEIGHBORS */
/* UIP_CONF_ND6_SEND_RA enables standard IPv6 Router Advertisement.
* We enable it by default when IPv6 is used without RPL. */
#ifndef UIP_CONF_ND6_SEND_RA
#define UIP_CONF_ND6_SEND_RA (NETSTACK_CONF_WITH_IPV6 && !UIP_CONF_IPV6_RPL)
#endif /* UIP_CONF_ND6_SEND_RA */
/* UIP_CONF_ND6_SEND_NA enables standard IPv6 Neighbor Discovery Protocol.
This is unneeded when RPL is used. Disable to save ROM and a little RAM. */
We enable it by default when IPv6 is used without RPL.
With RPL, the neighbor cache (link-local IPv6 <-> MAC address mapping)
is fed whenever receiving DIO and DAO messages. This is always sufficient
for RPL routing, i.e. to send to the preferred parent or any child.
Link-local unicast to other neighbors may, however, not be possible if
we never receive any DIO from them. This may happen if the link from the
neighbor to us is weak, if DIO transmissions are suppressed (Trickle
timer) or if the neighbor chooses not to transmit DIOs because it is
a leaf node or for any reason. */
#ifndef UIP_CONF_ND6_SEND_NA
#define UIP_CONF_ND6_SEND_NA 1
#define UIP_CONF_ND6_SEND_NA (NETSTACK_CONF_WITH_IPV6 && !UIP_CONF_IPV6_RPL)
#endif /* UIP_CONF_ND6_SEND_NA */
/*---------------------------------------------------------------------------*/

View File

@ -45,5 +45,6 @@
#define BUTTON_SENSOR_CONF_ON 1
#define UIP_CONF_ICMP6 1
#define RIMESTATS_CONF_ENABLED 1
#define UIP_CONF_ND6_SEND_NA 1
#endif /* PROJECT_CONF_H_ */

View File

@ -4,4 +4,5 @@ all: $(CONTIKI_PROJECT)
CONTIKI = ../../..
CONTIKI_WITH_IPV6 = 1
CFLAGS += -DUIP_CONF_ND6_SEND_NA=1
include $(CONTIKI)/Makefile.include

View File

@ -47,5 +47,6 @@
#define BUTTON_SENSOR_CONF_ON 1
#define RIMESTATS_CONF_ENABLED 1
#define VIZTOOL_CONF_ON 0
#define UIP_CONF_ND6_SEND_NA 1
#endif /* PROJECT_CONF_H_ */

View File

@ -2,4 +2,5 @@ all: udp-server udp-client
CONTIKI = ../..
CONTIKI_WITH_IPV6 = 1
CFLAGS += -DUIP_CONF_ND6_SEND_NA=1
include $(CONTIKI)/Makefile.include

View File

@ -1,4 +1,5 @@
#undef UIP_CONF_ND6_SEND_NA
#define UIP_CONF_ND6_SEND_NA 1
#ifdef BUFSIZE
#undef UIP_CONF_BUFFER_SIZE

View File

@ -1,4 +1,5 @@
#undef UIP_CONF_ND6_SEND_NA
#define UIP_CONF_ND6_SEND_NA 1
#ifdef BUFSIZE
#undef UIP_CONF_BUFFER_SIZE