From: Donatas Abraitis Date: Wed, 2 Sep 2020 05:44:27 +0000 (+0300) Subject: bgpd: Create separate udpate-group when using `maximum-prefix-out` command X-Git-Tag: frr-7.5~18^2~1 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=5abab4c435671b2bd98507fb63dab224ce1f77af;p=matthieu%2Ffrr.git bgpd: Create separate udpate-group when using `maximum-prefix-out` command This is needed to avoid mangling update-group which is used for many peers. Sent prefix count is managed by update-groups. Signed-off-by: Donatas Abraitis --- diff --git a/bgpd/bgp_updgrp.c b/bgpd/bgp_updgrp.c index ace18000f8..d2e563b237 100644 --- a/bgpd/bgp_updgrp.c +++ b/bgpd/bgp_updgrp.c @@ -373,11 +373,13 @@ static unsigned int updgrp_hash_key_make(const void *p) * There are certain peers that must get their own update-group: * - lonesoul peers * - peers that negotiated ORF + * - maximum-prefix-out is set */ if (CHECK_FLAG(peer->flags, PEER_FLAG_LONESOUL) || CHECK_FLAG(peer->af_cap[afi][safi], PEER_CAP_ORF_PREFIX_SM_RCV) || CHECK_FLAG(peer->af_cap[afi][safi], - PEER_CAP_ORF_PREFIX_SM_OLD_RCV)) + PEER_CAP_ORF_PREFIX_SM_OLD_RCV) + || CHECK_FLAG(peer->af_flags[afi][safi], PEER_FLAG_MAX_PREFIX_OUT)) key = jhash_1word(jhash(peer->host, strlen(peer->host), SEED2), key);