mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-14 00:56:19 +00:00
zebra: maintain mcast tunnel origination and termination SG entries
Each multicast tunnel is associated with a - 1. Tunnel origination mroute that is used for forwarding the VxLAN encapsulated flow - S - local VTEP-IP G - BUM mcast-group 2. And a tunnel termination entry - S - * (any remote VTEP) G - BUM mcast-group Multiple L2 VNIs can share the same BUM mcast group (and local-VTEP-IP). Zebra maintains an mcast (SG) hash table to pass this info to pimd for subsequent MDT setup. Signed-off-by: Anuradha Karuppiah <anuradhak@cumulusnetworks.com>
This commit is contained in:
parent
315999e9b4
commit
8a93734c48
@ -130,6 +130,9 @@ struct zebra_vrf {
|
||||
/* l3-vni info */
|
||||
vni_t l3vni;
|
||||
|
||||
/* pim mroutes installed for vxlan flooding */
|
||||
struct hash *vxlan_sg_table;
|
||||
|
||||
bool dup_addr_detect;
|
||||
|
||||
int dad_time;
|
||||
|
@ -58,6 +58,7 @@ DEFINE_MTYPE_STATIC(ZEBRA, ZL3VNI, "L3 VNI hash");
|
||||
DEFINE_MTYPE_STATIC(ZEBRA, ZVNI_VTEP, "VNI remote VTEP");
|
||||
DEFINE_MTYPE_STATIC(ZEBRA, MAC, "VNI MAC");
|
||||
DEFINE_MTYPE_STATIC(ZEBRA, NEIGH, "VNI Neighbor");
|
||||
DEFINE_MTYPE_STATIC(ZEBRA, ZVXLAN_SG, "zebra VxLAN multicast group");
|
||||
|
||||
/* definitions */
|
||||
/* PMSI strings. */
|
||||
|
@ -434,4 +434,26 @@ struct nh_walk_ctx {
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Multicast hash table.
|
||||
*
|
||||
* This table contains -
|
||||
* 1. The (S, G) entries used for encapsulating and forwarding BUM traffic.
|
||||
* S is the local VTEP-IP and G is a BUM mcast group address.
|
||||
* 2. The (X, G) entries used for terminating a BUM flow.
|
||||
* Multiple L2-VNIs can share the same MDT hence the need to maintain
|
||||
* an aggregated table that pimd can consume without much
|
||||
* re-interpretation.
|
||||
*/
|
||||
typedef struct zebra_vxlan_sg_ {
|
||||
struct zebra_vrf *zvrf;
|
||||
|
||||
struct prefix_sg sg;
|
||||
char sg_str[PREFIX_SG_STR_LEN];
|
||||
|
||||
/* For SG - num of L2 VNIs using this entry for sending BUM traffic */
|
||||
/* For XG - num of SG using this as parent */
|
||||
uint32_t ref_cnt;
|
||||
} zebra_vxlan_sg_t;
|
||||
|
||||
#endif /* _ZEBRA_VXLAN_PRIVATE_H */
|
||||
|
Loading…
Reference in New Issue
Block a user