Merge pull request #17488 from FRRouting/mergify/bp/stable/10.2/pr-17487

bgpd: Do not reset peers on suppress-fib toggling (backport #17487)
This commit is contained in:
Donald Sharp 2024-11-22 18:33:59 -05:00 committed by GitHub
commit c9975e1525
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -462,6 +462,10 @@ void bgp_suppress_fib_pending_set(struct bgp *bgp, bool set)
if (bgp->inst_type == BGP_INSTANCE_TYPE_VIEW) if (bgp->inst_type == BGP_INSTANCE_TYPE_VIEW)
return; return;
/* Do nothing if already in a desired state */
if (set == !!CHECK_FLAG(bgp->flags, BGP_FLAG_SUPPRESS_FIB_PENDING))
return;
if (set) { if (set) {
SET_FLAG(bgp->flags, BGP_FLAG_SUPPRESS_FIB_PENDING); SET_FLAG(bgp->flags, BGP_FLAG_SUPPRESS_FIB_PENDING);
/* Send msg to zebra for the first instance of bgp enabled /* Send msg to zebra for the first instance of bgp enabled