diff options
Diffstat (limited to 'bgpd/bgp_evpn.c')
| -rw-r--r-- | bgpd/bgp_evpn.c | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/bgpd/bgp_evpn.c b/bgpd/bgp_evpn.c index 488f635b81..0ebef2ecfe 100644 --- a/bgpd/bgp_evpn.c +++ b/bgpd/bgp_evpn.c @@ -905,7 +905,7 @@ static enum zclient_send_status bgp_zebra_send_remote_macip( bool esi_valid; /* Check socket. */ - if (!zclient || zclient->sock < 0) { + if (!bgp_zclient || bgp_zclient->sock < 0) { if (BGP_DEBUG(zebra, ZEBRA)) zlog_debug("%s: No zclient or zclient->sock exists", __func__); @@ -923,7 +923,7 @@ static enum zclient_send_status bgp_zebra_send_remote_macip( if (!esi) esi = zero_esi; - s = zclient->obuf; + s = bgp_zclient->obuf; stream_reset(s); zclient_create_header( @@ -984,7 +984,7 @@ static enum zclient_send_status bgp_zebra_send_remote_macip( frrtrace(5, frr_bgp, evpn_mac_ip_zsend, add, vpn, p, remote_vtep_ip, esi); - return zclient_send_message(zclient); + return zclient_send_message(bgp_zclient); } /* @@ -998,7 +998,7 @@ bgp_zebra_send_remote_vtep(struct bgp *bgp, struct bgpevpn *vpn, struct stream *s; /* Check socket. */ - if (!zclient || zclient->sock < 0) { + if (!bgp_zclient || bgp_zclient->sock < 0) { if (BGP_DEBUG(zebra, ZEBRA)) zlog_debug("%s: No zclient or zclient->sock exists", __func__); @@ -1014,7 +1014,7 @@ bgp_zebra_send_remote_vtep(struct bgp *bgp, struct bgpevpn *vpn, return ZCLIENT_SEND_SUCCESS; } - s = zclient->obuf; + s = bgp_zclient->obuf; stream_reset(s); zclient_create_header( @@ -1041,7 +1041,7 @@ bgp_zebra_send_remote_vtep(struct bgp *bgp, struct bgpevpn *vpn, frrtrace(3, frr_bgp, evpn_bum_vtep_zsend, add, vpn, p); - return zclient_send_message(zclient); + return zclient_send_message(bgp_zclient); } /* @@ -2062,8 +2062,7 @@ static int update_evpn_route_entry(struct bgp *bgp, struct bgpevpn *vpn, bgp_path_info_add(dest, tmp_pi); } else { tmp_pi = local_pi; - if (attrhash_cmp(tmp_pi->attr, attr) - && !CHECK_FLAG(tmp_pi->flags, BGP_PATH_REMOVED)) + if (!CHECK_FLAG(tmp_pi->flags, BGP_PATH_REMOVED) && attrhash_cmp(tmp_pi->attr, attr)) route_change = 0; else { /* @@ -3154,8 +3153,7 @@ static int install_evpn_route_entry_in_vrf(struct bgp *bgp_vrf, pi = bgp_create_evpn_bgp_path_info(parent_pi, dest, &attr); new_pi = true; } else { - if (attrhash_cmp(pi->attr, &attr) - && !CHECK_FLAG(pi->flags, BGP_PATH_REMOVED)) { + if (!CHECK_FLAG(pi->flags, BGP_PATH_REMOVED) && attrhash_cmp(pi->attr, &attr)) { bgp_dest_unlock_node(dest); return 0; } @@ -3184,8 +3182,7 @@ static int install_evpn_route_entry_in_vrf(struct bgp *bgp_vrf, /* Gateway IP nexthop should be resolved */ if (bre && bre->type == OVERLAY_INDEX_GATEWAY_IP) { - if (bgp_find_or_add_nexthop(bgp_vrf, bgp_vrf, afi, safi, pi, - NULL, 0, NULL)) + if (bgp_find_or_add_nexthop(bgp_vrf, bgp_vrf, afi, safi, pi, NULL, 0, NULL, NULL)) bgp_path_info_set_flag(dest, pi, BGP_PATH_VALID); else { if (BGP_DEBUG(nht, NHT)) { @@ -3278,8 +3275,8 @@ static int install_evpn_route_entry_in_vni_common( * install_evpn_route_entry_in_vni_mac() or * install_evpn_route_entry_in_vni_ip() */ - if (attrhash_cmp(pi->attr, parent_pi->attr) && - !CHECK_FLAG(pi->flags, BGP_PATH_REMOVED)) + if (!CHECK_FLAG(pi->flags, BGP_PATH_REMOVED) && + attrhash_cmp(pi->attr, parent_pi->attr)) return 0; /* The attribute has changed. */ /* Add (or update) attribute to hash. */ |
