From b69442d456fa6a00716c5a0684395b04f5794cd6 Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Tue, 13 Sep 2011 17:15:51 +0400 Subject: configure: dismiss libutil.h Recent versions of libc on Linux (Debian Testing) create lots of compile warnings about direct usage of libutil.h --- lib/zebra.h | 4 ---- 1 file changed, 4 deletions(-) (limited to 'lib/zebra.h') diff --git a/lib/zebra.h b/lib/zebra.h index 2dc84514..4afb20eb 100644 --- a/lib/zebra.h +++ b/lib/zebra.h @@ -237,10 +237,6 @@ typedef int socklen_t; #define UINT32_MAX (4294967295U) #endif -#ifdef HAVE_LIBUTIL_H -#include -#endif /* HAVE_LIBUTIL_H */ - #ifdef HAVE_GLIBC_BACKTRACE #include #endif /* HAVE_GLIBC_BACKTRACE */ -- cgit v1.2.1 From 0a28130d35bbba47faf47bf9451ba0eb195fcbb7 Mon Sep 17 00:00:00 2001 From: Denis Ovsienko Date: Sun, 17 Jul 2011 19:33:21 +0400 Subject: bgpd: rename SAFI 3 according to RFC4760 - SAFI value 3 is reserved. It was assigned by RFC 2858 for a use that was never fully implemented, so it is deprecated by this document. * zebra.h: rename macro * bgp_fsm.c: (bgp_graceful_restart_timer_expire, bgp_graceful_stale_timer_expire, bgp_stop, bgp_establish): update * bgpd.c: (peer_nsf_stop): update * bgp_open.c: (bgp_capability_vty_out): SAFI 3 isn't a recognized case any more --- lib/zebra.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/zebra.h') diff --git a/lib/zebra.h b/lib/zebra.h index 4afb20eb..c4c69d3d 100644 --- a/lib/zebra.h +++ b/lib/zebra.h @@ -500,7 +500,7 @@ extern const char *zserv_command_string (unsigned int command); /* Subsequent Address Family Identifier. */ #define SAFI_UNICAST 1 #define SAFI_MULTICAST 2 -#define SAFI_UNICAST_MULTICAST 3 +#define SAFI_RESERVED_3 3 #define SAFI_MPLS_VPN 4 #define SAFI_MAX 5 -- cgit v1.2.1 From e0ca5fde7be5b5ce90dae78c2477e8245aecb8e9 Mon Sep 17 00:00:00 2001 From: David Lamparter Date: Wed, 16 Sep 2009 01:52:42 +0200 Subject: lib: put route_types.txt to real use this replaces most occurences of routing protocol lists by preprocessor defines from route_types.h. the latter is autogenerated from route_types.txt by a perl script (previously awk). adding a routing protocol now is mostly a matter of changing route_types.txt and log.c. Conflicts: lib/route_types.awk --- lib/zebra.h | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) (limited to 'lib/zebra.h') diff --git a/lib/zebra.h b/lib/zebra.h index c4c69d3d..4b4c7c00 100644 --- a/lib/zebra.h +++ b/lib/zebra.h @@ -425,19 +425,8 @@ struct in_pktinfo */ #define ZEBRA_HEADER_MARKER 255 -/* Zebra route's types. */ -#define ZEBRA_ROUTE_SYSTEM 0 -#define ZEBRA_ROUTE_KERNEL 1 -#define ZEBRA_ROUTE_CONNECT 2 -#define ZEBRA_ROUTE_STATIC 3 -#define ZEBRA_ROUTE_RIP 4 -#define ZEBRA_ROUTE_RIPNG 5 -#define ZEBRA_ROUTE_OSPF 6 -#define ZEBRA_ROUTE_OSPF6 7 -#define ZEBRA_ROUTE_ISIS 8 -#define ZEBRA_ROUTE_BGP 9 -#define ZEBRA_ROUTE_HSLS 10 -#define ZEBRA_ROUTE_MAX 11 +/* Zebra route's types are defined in route_types.h */ +#include "route_types.h" /* Note: whenever a new route-type or zserv-command is added the * corresponding {command,route}_types[] table in lib/log.c MUST be @@ -451,6 +440,10 @@ extern char zebra_route_char(unsigned int route_type); * e.g. ZEBRA_INTERFACE_ADD -> "ZEBRA_INTERFACE_ADD" */ /* Map a protocol name to its number. e.g. ZEBRA_ROUTE_BGP->9*/ extern int proto_name2num(const char *s); +/* Map redistribute X argument to protocol number. + * unlike proto_name2num, this accepts shorthands and takes + * an AFI value to restrict input */ +extern int proto_redistnum(int afi, const char *s); extern const char *zserv_command_string (unsigned int command); -- cgit v1.2.1 From 2ea1ab1c30c765cd4703794fcfaf044454fb533c Mon Sep 17 00:00:00 2001 From: Vyacheslav Trushkin Date: Sun, 11 Dec 2011 18:48:47 +0400 Subject: zebra: ZEBRA_HELLO and mopping up routes (BZ#448) ZEBRA_HELLO message is used by routing daemons to inform zebra what type of routes daemon will be announcing to zebra. Also zebra uses route_type_oaths array to track which daemon announces which protocol. Zebra mops up routes if daemon didn't for some reason. --- lib/zebra.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/zebra.h') diff --git a/lib/zebra.h b/lib/zebra.h index 4b4c7c00..ab072d6e 100644 --- a/lib/zebra.h +++ b/lib/zebra.h @@ -417,7 +417,8 @@ struct in_pktinfo #define ZEBRA_ROUTER_ID_ADD 20 #define ZEBRA_ROUTER_ID_DELETE 21 #define ZEBRA_ROUTER_ID_UPDATE 22 -#define ZEBRA_MESSAGE_MAX 23 +#define ZEBRA_HELLO 23 +#define ZEBRA_MESSAGE_MAX 24 /* Marker value used in new Zserv, in the byte location corresponding * the command value in the old zserv header. To allow old and new -- cgit v1.2.1