diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2023-04-18 17:21:13 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2023-04-18 17:21:13 +0200 |
commit | 02164814b49a3385caae0ea10aa042487c6002d2 (patch) | |
tree | 697c985f8b4a1a5c072d0e386bf4fa41ca43c602 /proto/bgp | |
parent | fbeef4b74dfd73fb86b1ccc5dd1c6109e3c21624 (diff) |
BMP: Allow build without BMP and disable BMP build by default
It has still several important issues to be enabled by default.
Diffstat (limited to 'proto/bgp')
-rw-r--r-- | proto/bgp/bgp.c | 5 | ||||
-rw-r--r-- | proto/bgp/packets.c | 6 |
2 files changed, 10 insertions, 1 deletions
diff --git a/proto/bgp/bgp.c b/proto/bgp/bgp.c index a6d30eff..c806765a 100644 --- a/proto/bgp/bgp.c +++ b/proto/bgp/bgp.c @@ -1694,7 +1694,6 @@ bgp_init(struct proto_config *CF) struct bgp_config *cf = (struct bgp_config *) CF; P->rt_notify = bgp_rt_notify; - P->rte_update_in_notify = bgp_rte_update_in_notify; P->preexport = bgp_preexport; P->neigh_notify = bgp_neigh_notify; P->reload_routes = bgp_reload_routes; @@ -1706,6 +1705,10 @@ bgp_init(struct proto_config *CF) P->rte_modify = bgp_rte_modify_stale; P->rte_igp_metric = bgp_rte_igp_metric; +#ifdef CONFIG_BMP + P->rte_update_in_notify = bgp_rte_update_in_notify; +#endif + p->cf = cf; p->is_internal = (cf->local_as == cf->remote_as); p->is_interior = p->is_internal || cf->confederation_member; diff --git a/proto/bgp/packets.c b/proto/bgp/packets.c index 42016eae..b9537169 100644 --- a/proto/bgp/packets.c +++ b/proto/bgp/packets.c @@ -2407,6 +2407,9 @@ bgp_create_mp_unreach(struct bgp_write_state *s, struct bgp_bucket *buck, byte * return buf+11+len; } + +#ifdef CONFIG_BMP + static byte * bgp_create_update_bmp(struct bgp_channel *c, byte *buf, struct bgp_bucket *buck, bool update) { @@ -2489,6 +2492,9 @@ bgp_rte_update_in_notify(struct channel *C, const net_addr *n, bmp_route_monitor_put_update_in_pre_msg(buf, end - buf); } +#endif /* CONFIG_BMP */ + + static byte * bgp_create_update(struct bgp_channel *c, byte *buf) { |