From 272e11bfc4be93a57867834edf950804680697dd Mon Sep 17 00:00:00 2001 From: Mark Stapp Date: Fri, 16 Apr 2021 12:17:11 -0400 Subject: [PATCH] zebra: give some evpn apis better names Use more useful names for a few evpn apis. Signed-off-by: Mark Stapp --- zebra/zebra_evpn.c | 13 +++++++------ zebra/zebra_evpn.h | 4 ++-- zebra/zebra_evpn_mac.c | 10 +++++----- zebra/zebra_evpn_mac.h | 10 +++++----- zebra/zebra_evpn_neigh.c | 9 +++++---- zebra/zebra_evpn_neigh.h | 9 +++++---- zebra/zebra_vxlan.c | 4 ++-- 7 files changed, 31 insertions(+), 28 deletions(-) diff --git a/zebra/zebra_evpn.c b/zebra/zebra_evpn.c index 816f46bac9..8e73e86139 100644 --- a/zebra/zebra_evpn.c +++ b/zebra/zebra_evpn.c @@ -1380,7 +1380,7 @@ zebra_evpn_process_sync_macip_add(zebra_evpn_t *zevpn, struct ethaddr *macaddr, /************************** remote mac-ip handling **************************/ /* Process a remote MACIP add from BGP. */ -void process_remote_macip_add(vni_t vni, struct ethaddr *macaddr, +void zebra_evpn_rem_macip_add(vni_t vni, struct ethaddr *macaddr, uint16_t ipa_len, struct ipaddr *ipaddr, uint8_t flags, uint32_t seq, struct in_addr vtep_ip, esi_t *esi) @@ -1447,17 +1447,18 @@ void process_remote_macip_add(vni_t vni, struct ethaddr *macaddr, return; - if (process_mac_remote_macip_add(zevpn, zvrf, macaddr, ipa_len, ipaddr, - &mac, vtep_ip, flags, seq, esi) + if (zebra_evpn_mac_remote_macip_add(zevpn, zvrf, macaddr, ipa_len, + ipaddr, &mac, vtep_ip, flags, seq, + esi) != 0) return; - process_neigh_remote_macip_add(zevpn, zvrf, ipaddr, mac, vtep_ip, flags, - seq); + zebra_evpn_neigh_remote_macip_add(zevpn, zvrf, ipaddr, mac, vtep_ip, + flags, seq); } /* Process a remote MACIP delete from BGP. */ -void process_remote_macip_del(vni_t vni, struct ethaddr *macaddr, +void zebra_evpn_rem_macip_del(vni_t vni, struct ethaddr *macaddr, uint16_t ipa_len, struct ipaddr *ipaddr, struct in_addr vtep_ip) { diff --git a/zebra/zebra_evpn.h b/zebra/zebra_evpn.h index ee9e1406e4..f7837d09a8 100644 --- a/zebra/zebra_evpn.h +++ b/zebra/zebra_evpn.h @@ -204,11 +204,11 @@ int zebra_evpn_vtep_uninstall(zebra_evpn_t *zevpn, struct in_addr *vtep_ip); void zebra_evpn_handle_flooding_remote_vteps(struct hash_bucket *bucket, void *zvrf); void zebra_evpn_cleanup_all(struct hash_bucket *bucket, void *arg); -void process_remote_macip_add(vni_t vni, struct ethaddr *macaddr, +void zebra_evpn_rem_macip_add(vni_t vni, struct ethaddr *macaddr, uint16_t ipa_len, struct ipaddr *ipaddr, uint8_t flags, uint32_t seq, struct in_addr vtep_ip, esi_t *esi); -void process_remote_macip_del(vni_t vni, struct ethaddr *macaddr, +void zebra_evpn_rem_macip_del(vni_t vni, struct ethaddr *macaddr, uint16_t ipa_len, struct ipaddr *ipaddr, struct in_addr vtep_ip); void zebra_evpn_cfg_cleanup(struct hash_bucket *bucket, void *ctxt); diff --git a/zebra/zebra_evpn_mac.c b/zebra/zebra_evpn_mac.c index fe3167dc29..26694245f1 100644 --- a/zebra/zebra_evpn_mac.c +++ b/zebra/zebra_evpn_mac.c @@ -1958,11 +1958,11 @@ void zebra_evpn_print_dad_mac_hash_detail(struct hash_bucket *bucket, zebra_evpn_print_mac_hash_detail(bucket, ctxt); } -int process_mac_remote_macip_add(zebra_evpn_t *zevpn, struct zebra_vrf *zvrf, - struct ethaddr *macaddr, uint16_t ipa_len, - struct ipaddr *ipaddr, zebra_mac_t **macp, - struct in_addr vtep_ip, uint8_t flags, - uint32_t seq, esi_t *esi) +int zebra_evpn_mac_remote_macip_add(zebra_evpn_t *zevpn, struct zebra_vrf *zvrf, + struct ethaddr *macaddr, uint16_t ipa_len, + struct ipaddr *ipaddr, zebra_mac_t **macp, + struct in_addr vtep_ip, uint8_t flags, + uint32_t seq, esi_t *esi) { char buf1[INET6_ADDRSTRLEN]; bool sticky; diff --git a/zebra/zebra_evpn_mac.h b/zebra/zebra_evpn_mac.h index fb162f1a93..5d17e283ae 100644 --- a/zebra/zebra_evpn_mac.h +++ b/zebra/zebra_evpn_mac.h @@ -262,11 +262,11 @@ void zebra_evpn_rem_mac_del(zebra_evpn_t *zevi, zebra_mac_t *mac); void zebra_evpn_print_dad_mac_hash(struct hash_bucket *bucket, void *ctxt); void zebra_evpn_print_dad_mac_hash_detail(struct hash_bucket *bucket, void *ctxt); -int process_mac_remote_macip_add(zebra_evpn_t *zevpn, struct zebra_vrf *zvrf, - struct ethaddr *macaddr, uint16_t ipa_len, - struct ipaddr *ipaddr, zebra_mac_t **macp, - struct in_addr vtep_ip, uint8_t flags, - uint32_t seq, esi_t *esi); +int zebra_evpn_mac_remote_macip_add(zebra_evpn_t *zevpn, struct zebra_vrf *zvrf, + struct ethaddr *macaddr, uint16_t ipa_len, + struct ipaddr *ipaddr, zebra_mac_t **macp, + struct in_addr vtep_ip, uint8_t flags, + uint32_t seq, esi_t *esi); int zebra_evpn_add_update_local_mac(struct zebra_vrf *zvrf, zebra_evpn_t *zevpn, struct interface *ifp, diff --git a/zebra/zebra_evpn_neigh.c b/zebra/zebra_evpn_neigh.c index 4c7a1542fc..a78bac010c 100644 --- a/zebra/zebra_evpn_neigh.c +++ b/zebra/zebra_evpn_neigh.c @@ -2046,10 +2046,11 @@ void zebra_evpn_print_dad_neigh_hash_detail(struct hash_bucket *bucket, zebra_evpn_print_neigh_hash_detail(bucket, ctxt); } -void process_neigh_remote_macip_add(zebra_evpn_t *zevpn, struct zebra_vrf *zvrf, - struct ipaddr *ipaddr, zebra_mac_t *mac, - struct in_addr vtep_ip, uint8_t flags, - uint32_t seq) +void zebra_evpn_neigh_remote_macip_add(zebra_evpn_t *zevpn, + struct zebra_vrf *zvrf, + struct ipaddr *ipaddr, zebra_mac_t *mac, + struct in_addr vtep_ip, uint8_t flags, + uint32_t seq) { zebra_neigh_t *n; int update_neigh = 0; diff --git a/zebra/zebra_evpn_neigh.h b/zebra/zebra_evpn_neigh.h index 05156c1255..fdfe6dc1d0 100644 --- a/zebra/zebra_evpn_neigh.h +++ b/zebra/zebra_evpn_neigh.h @@ -266,10 +266,11 @@ void zebra_evpn_print_neigh_hash_detail(struct hash_bucket *bucket, void *ctxt); void zebra_evpn_print_dad_neigh_hash(struct hash_bucket *bucket, void *ctxt); void zebra_evpn_print_dad_neigh_hash_detail(struct hash_bucket *bucket, void *ctxt); -void process_neigh_remote_macip_add(zebra_evpn_t *zevpn, struct zebra_vrf *zvrf, - struct ipaddr *ipaddr, zebra_mac_t *mac, - struct in_addr vtep_ip, uint8_t flags, - uint32_t seq); +void zebra_evpn_neigh_remote_macip_add(zebra_evpn_t *zevpn, + struct zebra_vrf *zvrf, + struct ipaddr *ipaddr, zebra_mac_t *mac, + struct in_addr vtep_ip, uint8_t flags, + uint32_t seq); int zebra_evpn_neigh_gw_macip_add(struct interface *ifp, zebra_evpn_t *zevpn, struct ipaddr *ip, zebra_mac_t *mac); void zebra_evpn_neigh_remote_uninstall(zebra_evpn_t *zevpn, diff --git a/zebra/zebra_vxlan.c b/zebra/zebra_vxlan.c index 2f3ea7475a..b434433e17 100644 --- a/zebra/zebra_vxlan.c +++ b/zebra/zebra_vxlan.c @@ -3844,7 +3844,7 @@ void zebra_vxlan_remote_macip_del(ZAPI_HANDLER_ARGS) ipaddr2str(&ip, buf1, sizeof(buf1)) : "", &vtep_ip, zebra_route_string(client->proto)); - process_remote_macip_del(vni, &macaddr, ipa_len, &ip, vtep_ip); + zebra_evpn_rem_macip_del(vni, &macaddr, ipa_len, &ip, vtep_ip); } stream_failure: @@ -3907,7 +3907,7 @@ void zebra_vxlan_remote_macip_add(ZAPI_HANDLER_ARGS) zebra_route_string(client->proto)); } - process_remote_macip_add(vni, &macaddr, ipa_len, &ip, + zebra_evpn_rem_macip_add(vni, &macaddr, ipa_len, &ip, flags, seq, vtep_ip, &esi); } -- 2.39.5