diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2010-11-03 01:40:36 +0100 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2010-11-03 01:40:36 +0100 |
commit | a244c5524b30874e24fc4dfbdb8cef243bd33178 (patch) | |
tree | 2856262ff6d1cbb9470dde9e7f4cabd3030ef973 /proto/bgp/bgp.h | |
parent | 938b191b9282b138cbdd30dfc11b78c0467d6380 (diff) | |
download | bird-a244c5524b30874e24fc4dfbdb8cef243bd33178.tar bird-a244c5524b30874e24fc4dfbdb8cef243bd33178.zip |
Added support for sending and handling the multicast capability
Diffstat (limited to 'proto/bgp/bgp.h')
-rw-r--r-- | proto/bgp/bgp.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/proto/bgp/bgp.h b/proto/bgp/bgp.h index b06f20a..359bd9c 100644 --- a/proto/bgp/bgp.h +++ b/proto/bgp/bgp.h @@ -32,6 +32,7 @@ struct bgp_config { int capabilities; /* Enable capability handshake [RFC3392] */ int enable_refresh; /* Enable local support for route refresh [RFC2918] */ int enable_as4; /* Enable local support for 4B AS numbers [RFC4893] */ + int enable_multicast; /* Enable local support for multicast routes [RFC4760] */ u32 rr_cluster_id; /* Route reflector cluster ID, if different from local ID */ int rr_client; /* Whether neighbor is RR client of me */ int rs_client; /* Whether neighbor is RS client of me */ @@ -73,6 +74,8 @@ struct bgp_conn { int start_state; /* protocol start_state snapshot when connection established */ int want_as4_support; /* Connection tries to establish AS4 session */ int peer_as4_support; /* Peer supports 4B AS numbers [RFC4893] */ + int want_multicast_support; /* We want to exchange multicast routes */ + int peer_multicast_support; /* Peer supports multicast routes [RFC4760] */ int peer_refresh_support; /* Peer supports route refresh [RFC2918] */ unsigned hold_time, keepalive_time; /* Times calculated from my and neighbor's requirements */ }; @@ -108,11 +111,9 @@ struct bgp_proto { u8 last_error_class; /* Error class of last error */ u32 last_error_code; /* Error code of last error. BGP protocol errors are encoded as (bgp_err_code << 16 | bgp_err_subcode) */ -#ifdef IPV6 byte *mp_reach_start, *mp_unreach_start; /* Multiprotocol BGP attribute notes */ unsigned mp_reach_len, mp_unreach_len; ip_addr local_link; /* Link-level version of source_addr */ -#endif }; struct bgp_prefix { @@ -297,6 +298,12 @@ void bgp_log_error(struct bgp_proto *p, u8 class, char *msg, unsigned code, unsi #define ORIGIN_EGP 1 #define ORIGIN_INCOMPLETE 2 +/* Capabilities */ + +#define BGP_CAP_MP 1 +#define BGP_CAP_REFRESH 2 +#define BGP_CAP_AS4 65 + /* Address families */ #define BGP_AF_IPV4 1 @@ -308,4 +315,7 @@ void bgp_log_error(struct bgp_proto *p, u8 class, char *msg, unsigned code, unsi #define BGP_AF BGP_AF_IPV4 #endif +#define BGP_SAF_UNICAST 1 +#define BGP_SAF_MULTICAST 2 + #endif |