From 1d32a00ebddea746abdca4ff51e7a56233fa93fa Mon Sep 17 00:00:00 2001 From: Mohamed Seliem Date: Thu, 7 Jul 2016 12:03:53 +0200 Subject: [PATCH] Fix uip-ds.h table configuration comment this PR to update uip-ds.h comments, this small change is made to ease the track of Tables implementation places remove definition of UIP_CONF_DS6_ROUTE_NBU retire 2 old macros DS6_NBR_NBU, DS6_ROUTE_NBU Update uip-ds6.h Update contiki-conf.h Update contiki-conf.h Update contiki-conf.h fix doxygen comment Update uip-ds6.h --- core/net/ipv6/uip-ds6-route.h | 10 +++------- core/net/ipv6/uip-ds6.h | 2 ++ examples/ipv6/multicast/project-conf.h | 8 ++++---- platform/mbxxx/contiki-conf.h | 2 +- platform/seedeye/contiki-conf.h | 2 +- platform/stm32nucleo-spirit1/contiki-conf.h | 6 +++--- 6 files changed, 14 insertions(+), 16 deletions(-) diff --git a/core/net/ipv6/uip-ds6-route.h b/core/net/ipv6/uip-ds6-route.h index 6855fc2cd..d6f88e943 100644 --- a/core/net/ipv6/uip-ds6-route.h +++ b/core/net/ipv6/uip-ds6-route.h @@ -82,14 +82,10 @@ void uip_ds6_notification_rm(struct uip_ds6_notification *n); #endif /* Routing table */ -#ifndef UIP_CONF_MAX_ROUTES -#ifdef UIP_CONF_DS6_ROUTE_NBU -#define UIP_DS6_ROUTE_NB UIP_CONF_DS6_ROUTE_NBU -#else /* UIP_CONF_DS6_ROUTE_NBU */ -#define UIP_DS6_ROUTE_NB 4 -#endif /* UIP_CONF_DS6_ROUTE_NBU */ -#else /* UIP_CONF_MAX_ROUTES */ +#ifdef UIP_CONF_MAX_ROUTES #define UIP_DS6_ROUTE_NB UIP_CONF_MAX_ROUTES +#else /* UIP_CONF_MAX_ROUTES */ +#define UIP_DS6_ROUTE_NB 4 #endif /* UIP_CONF_MAX_ROUTES */ /** \brief define some additional RPL related route state and diff --git a/core/net/ipv6/uip-ds6.h b/core/net/ipv6/uip-ds6.h index 294eb230c..8803729a0 100644 --- a/core/net/ipv6/uip-ds6.h +++ b/core/net/ipv6/uip-ds6.h @@ -56,6 +56,8 @@ * - the number of elements requested by the user in contiki configuration (name suffixed by _NBU) * - the number of elements assigned by the system (name suffixed by _NBS) * - the total number of elements is the sum (name suffixed by _NB) + * The routing table definitions can be found in uip-ds6-route.h + * The Neighbor cache definitions can be found in nbr-table.h */ /* Default router list */ diff --git a/examples/ipv6/multicast/project-conf.h b/examples/ipv6/multicast/project-conf.h index 8df6d01b4..0c47ab538 100644 --- a/examples/ipv6/multicast/project-conf.h +++ b/examples/ipv6/multicast/project-conf.h @@ -60,9 +60,9 @@ #define UIP_CONF_TCP 0 /* Code/RAM footprint savings so that things will fit on our device */ -#undef UIP_CONF_DS6_NBR_NBU -#undef UIP_CONF_DS6_ROUTE_NBU -#define UIP_CONF_DS6_NBR_NBU 10 -#define UIP_CONF_DS6_ROUTE_NBU 10 +#undef NBR_TABLE_CONF_MAX_NEIGHBORS +#undef UIP_CONF_MAX_ROUTES +#define NBR_TABLE_CONF_MAX_NEIGHBORS 10 +#define UIP_CONF_MAX_ROUTES 10 #endif /* PROJECT_CONF_H_ */ diff --git a/platform/mbxxx/contiki-conf.h b/platform/mbxxx/contiki-conf.h index 1d2b17322..4b1e3aac6 100644 --- a/platform/mbxxx/contiki-conf.h +++ b/platform/mbxxx/contiki-conf.h @@ -109,7 +109,7 @@ #define QUEUEBUF_CONF_NUM 2 #define QUEUEBUF_CONF_REF_NUM 0 #define NBR_TABLE_CONF_MAX_NEIGHBORS 4 -#define UIP_CONF_DS6_ROUTE_NBU 4 +#define UIP_CONF_MAX_ROUTES 4 #define RPL_CONF_MAX_PARENTS_PER_DAG 4 #define RPL_CONF_MAX_INSTANCES 1 #define RPL_CONF_MAX_DAG_PER_INSTANCE 1 diff --git a/platform/seedeye/contiki-conf.h b/platform/seedeye/contiki-conf.h index d58ff686d..de0d18c57 100644 --- a/platform/seedeye/contiki-conf.h +++ b/platform/seedeye/contiki-conf.h @@ -93,7 +93,7 @@ typedef uint32_t rtimer_clock_t; /* IPv6 configuration options */ #define NETSTACK_CONF_WITH_IPV6 1 #define NBR_TABLE_CONF_MAX_NEIGHBORS 20 /* number of neighbors */ -#define UIP_CONF_DS6_ROUTE_NBU 20 /* number of routes */ +#define UIP_CONF_MAX_ROUTES 20 /* number of routes */ #define UIP_CONF_ND6_SEND_RA 0 #define UIP_CONF_ND6_REACHABLE_TIME 600000 #define UIP_CONF_ND6_RETRANS_TIMER 10000 diff --git a/platform/stm32nucleo-spirit1/contiki-conf.h b/platform/stm32nucleo-spirit1/contiki-conf.h index 9a97ab355..43a3d8d9f 100644 --- a/platform/stm32nucleo-spirit1/contiki-conf.h +++ b/platform/stm32nucleo-spirit1/contiki-conf.h @@ -85,9 +85,9 @@ #define UIP_CONF_ROUTER 1 /* configure number of neighbors and routes */ -#ifndef UIP_CONF_DS6_ROUTE_NBU -#define UIP_CONF_DS6_ROUTE_NBU 30 -#endif /* UIP_CONF_DS6_ROUTE_NBU */ +#ifndef UIP_CONF_MAX_ROUTES +#define UIP_CONF_MAX_ROUTES 30 +#endif /* UIP_CONF_MAX_ROUTES */ #define UIP_CONF_ND6_SEND_RA 0 #define UIP_CONF_ND6_REACHABLE_TIME 600000 /* 90000// 600000 */