summaryrefslogtreecommitdiffstats
path: root/lib/ns.h
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2018-01-10 14:13:50 +0100
committerPhilippe Guibert <philippe.guibert@6wind.com>2018-01-22 13:52:24 +0100
commit3eca551fecb96994c076512e6e553d6035030865 (patch)
tree428be5dbf72b29104d73996fda9492c0a8da258b /lib/ns.h
parentlib: vrf_bitmap_groups increased from 8 to 1024 (diff)
downloadfrr-3eca551fecb96994c076512e6e553d6035030865.tar.xz
frr-3eca551fecb96994c076512e6e553d6035030865.zip
lib: ns_id_t changed to 32 bit
Because the VRF_ID is mapped into 32 bit, and because when NETNS will be the backend of VRF, then the NS identifier must also be encoded as 32 bit. Also, the NS_UNKNOWN value is changed accordingly to UINT32_MAX. Also, the NS_UNKNOWN and NS_DEFAULT values are removed from zebra_ns.h and kept on ns.h header file. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'lib/ns.h')
-rw-r--r--lib/ns.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/ns.h b/lib/ns.h
index c492d6600..79b4cab04 100644
--- a/lib/ns.h
+++ b/lib/ns.h
@@ -25,10 +25,11 @@
#include "openbsd-tree.h"
#include "linklist.h"
-typedef u_int16_t ns_id_t;
+typedef u_int32_t ns_id_t;
-/* The default NS ID */
+/* the default NS ID */
#define NS_DEFAULT 0
+#define NS_UNKNOWN UINT32_MAX
/* Default netns directory (Linux) */
#define NS_RUN_DIR "/var/run/netns"