summaryrefslogtreecommitdiff
path: root/zebra/zebra_evpn_mh.h
diff options
context:
space:
mode:
authorSharath Ramamurthy <sramamurthy@nvidia.com>2021-07-27 14:28:59 +0530
committerStephen Worley <sworley@nvidia.com>2023-02-13 18:12:04 -0500
commit239b26f932e5b78828dce8f7fe628c12b7ddbd9f (patch)
tree670abbd743f13e7daceb5ea652fcb2d0073b3cb7 /zebra/zebra_evpn_mh.h
parent131a9a2eeddab0f528b4ad6d29f0f4081cf8d8fe (diff)
zebra: multiple vlan aware bridge data structure and related changes
Multiple vlan aware bridge data structure changes and its corresponding bridge handling changes. A new vlan-table is maintained for each bridge which records the zebra_l2_bridge_vlan entry. zebra_l2_bridge_vlan maps vlan to access_bd associated to this bridge. Existing zebra_evpn_access_bd structure is vlan aware which is now modified to be (vlan, bridge) aware. Whenever a new access_bd is instantiated, a corresponding entry is also recorded in the zebra l2 bridge for the vlan. When the access_bd is dereferenced or whenever a bridge is deleted, the association is cleaned up. Signed-off-by: Sharath Ramamurthy <sramamurthy@nvidia.com>
Diffstat (limited to 'zebra/zebra_evpn_mh.h')
-rw-r--r--zebra/zebra_evpn_mh.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/zebra/zebra_evpn_mh.h b/zebra/zebra_evpn_mh.h
index 2c6e4924f6..12a8569504 100644
--- a/zebra/zebra_evpn_mh.h
+++ b/zebra/zebra_evpn_mh.h
@@ -179,6 +179,9 @@ struct zebra_evpn_es_vtep {
struct zebra_evpn_access_bd {
vlanid_t vid;
+ ifindex_t bridge_ifindex;
+ struct zebra_if *bridge_zif; /* associated bridge */
+
vni_t vni; /* vni associated with the vxlan device */
struct zebra_if *vxlan_zif; /* vxlan device */
/* list of members associated with the BD i.e. (potential) ESs */
@@ -348,9 +351,12 @@ extern void zebra_evpn_interface_init(void);
extern int zebra_evpn_mh_if_write(struct vty *vty, struct interface *ifp);
extern void zebra_evpn_acc_vl_show(struct vty *vty, bool uj);
extern void zebra_evpn_acc_vl_show_detail(struct vty *vty, bool uj);
-extern void zebra_evpn_acc_vl_show_vid(struct vty *vty, bool uj, vlanid_t vid);
extern void zebra_evpn_if_es_print(struct vty *vty, json_object *json,
struct zebra_if *zif);
+extern struct zebra_evpn_access_bd *
+zebra_evpn_acc_vl_find(vlanid_t vid, struct interface *br_if);
+extern void zebra_evpn_acc_vl_show_vid(struct vty *vty, bool uj, vlanid_t vid,
+ struct interface *br_if);
extern void zebra_evpn_es_cleanup(void);
extern int zebra_evpn_mh_mac_holdtime_update(struct vty *vty,
uint32_t duration, bool set_default);
@@ -376,6 +382,9 @@ extern void zebra_evpn_l2_nh_show(struct vty *vty, bool uj);
extern void zebra_evpn_acc_bd_svi_set(struct zebra_if *vlan_zif,
struct zebra_if *br_zif, bool is_up);
extern void zebra_evpn_acc_bd_svi_mac_add(struct interface *vlan_if);
+extern void
+zebra_evpn_access_bd_bridge_cleanup(vlanid_t vid, struct interface *br_if,
+ struct zebra_evpn_access_bd *acc_bd);
extern void zebra_evpn_es_bypass_update(struct zebra_evpn_es *es,
struct interface *ifp, bool bypass);
extern void zebra_evpn_proc_remote_nh(ZAPI_HANDLER_ARGS);