summaryrefslogtreecommitdiff
path: root/zebra/zebra_evpn_neigh.c
diff options
context:
space:
mode:
authorStephen Worley <sworley@nvidia.com>2021-10-26 17:48:49 -0400
committerStephen Worley <sworley@nvidia.com>2022-10-11 15:18:39 -0400
commit1e1398e3daa4c63c18da8e1f49b3c20bac6a3490 (patch)
tree291e64b06aafbf4fc4bd963bcf10e86ac8f211e5 /zebra/zebra_evpn_neigh.c
parent34c7f35f0217e16447ca0bc6aedd8aba2e51f877 (diff)
zebra: special sync routes lower seq handling
Add some special handling to accept lower seq routes for local known routes when not ready. This aligns the code back a bit more to where it was before to fix seen issues with sync routes. Signed-off-by: Stephen Worley <sworley@nvidia.com>
Diffstat (limited to 'zebra/zebra_evpn_neigh.c')
-rw-r--r--zebra/zebra_evpn_neigh.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/zebra/zebra_evpn_neigh.c b/zebra/zebra_evpn_neigh.c
index c187b5947f..7b5f1fc240 100644
--- a/zebra/zebra_evpn_neigh.c
+++ b/zebra/zebra_evpn_neigh.c
@@ -501,20 +501,33 @@ bool zebra_evpn_neigh_is_bgp_seq_ok(struct zebra_evpn *zevpn,
{
uint32_t tmp_seq;
const char *n_type;
+ bool is_local = false;
if (CHECK_FLAG(n->flags, ZEBRA_NEIGH_LOCAL)) {
tmp_seq = n->loc_seq;
n_type = "local";
+ is_local = true;
} else {
tmp_seq = n->rem_seq;
n_type = "remote";
}
if (seq < tmp_seq) {
+ if (is_local && !zebra_evpn_neigh_is_ready_for_bgp(n)) {
+ if (IS_ZEBRA_DEBUG_EVPN_MH_NEIGH ||
+ IS_ZEBRA_DEBUG_VXLAN)
+ zlog_debug(
+ "%s-macip not ready vni %u %s mac %pEA IP %pIA lower seq %u f 0x%x",
+ sync ? "sync" : "remote", zevpn->vni,
+ n_type, macaddr, &n->ip, tmp_seq,
+ n->flags);
+ return true;
+ }
+
/* if the neigh was never advertised to bgp we must accept
* whatever sequence number bgp sends
*/
- if (zebra_vxlan_accept_bgp_seq()) {
+ if (!is_local && zebra_vxlan_accept_bgp_seq()) {
if (IS_ZEBRA_DEBUG_EVPN_MH_NEIGH
|| IS_ZEBRA_DEBUG_VXLAN)
zlog_debug(