summaryrefslogtreecommitdiff
path: root/zebra/zebra_vxlan_if.h
diff options
context:
space:
mode:
authorSharath Ramamurthy <sramamurthy@nvidia.com>2021-07-27 13:50:55 +0530
committerStephen Worley <sworley@nvidia.com>2023-02-13 18:12:04 -0500
commit96c25556a1c1660d2a4f852ff7ab14e698d4387c (patch)
treee1c1be513efbe0c24d290fbc16621db1a28be0d3 /zebra/zebra_vxlan_if.h
parent0adeb5fdf46fe23a85924d04f2f02ee0be3cce6a (diff)
zebra: vxlan interface handling changes
This change modifies zebra_vxlan_if_up/down/add/update and del functionality to be per vni based. zebra_vxlan_if_add/update/del and zebra_vxlan_if_up/down now handles the vni operations based on vxlan device type (single or traditional vxlan device). zebra_vxlan_if_vni_table_add_update - This function handles the vlan-vni map update received from the netlink interface to single vxlan device vni_table hash table. zebra_vxlan_if_vni_mcast_group_update - This function handles the new multicast group update received from the netlink interface to single vxlan device vni_table hash table. For traditional vxlan interfaces, the vni and mcast group handling follows the traditional approach. Signed-off-by: Sharath Ramamurthy <sramamurthy@nvidia.com>
Diffstat (limited to 'zebra/zebra_vxlan_if.h')
-rw-r--r--zebra/zebra_vxlan_if.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/zebra/zebra_vxlan_if.h b/zebra/zebra_vxlan_if.h
index 721e2b87ad..c70b2f8fc6 100644
--- a/zebra/zebra_vxlan_if.h
+++ b/zebra/zebra_vxlan_if.h
@@ -42,10 +42,46 @@
extern "C" {
#endif
+extern void *zebra_vxlan_vni_alloc(void *p);
+extern void zebra_vxlan_vni_free(void *arg);
+extern struct hash *zebra_vxlan_vni_table_create(void);
+extern void zebra_vxlan_vni_table_destroy(struct hash *vni_table);
+extern int zebra_vxlan_if_vni_table_create(struct zebra_if *zif);
+extern int zebra_vxlan_if_vni_table_destroy(struct zebra_if *zif);
+extern struct zebra_vxlan_vni *
+zebra_vxlan_if_vni_find(const struct zebra_if *zif, vni_t vni);
+extern void zebra_vxlan_if_vni_iterate(struct zebra_if *zif,
+ int (*func)(struct zebra_if *zif,
+ struct zebra_vxlan_vni *,
+ void *),
+ void *arg);
+extern void zebra_vxlan_if_vni_walk(struct zebra_if *zif,
+ int (*func)(struct zebra_if *zif,
+ struct zebra_vxlan_vni *,
+ void *),
+ void *arg);
+extern struct zebra_vxlan_vni *
+zebra_vxlan_if_access_vlan_find(struct zebra_if *zif, uint8_t vlan_aware,
+ vlanid_t vid);
+extern int zebra_vxlan_if_vni_mcast_group_update(struct interface *ifp,
+ vni_t vni_id,
+ struct in_addr *mcast_group);
+extern int zebra_vxlan_if_vni_down(struct interface *ifp,
+ struct zebra_vxlan_vni *vni);
extern int zebra_vxlan_if_down(struct interface *ifp);
+extern int zebra_vxlan_if_vni_up(struct interface *ifp,
+ struct zebra_vxlan_vni *vni);
extern int zebra_vxlan_if_up(struct interface *ifp);
+extern int zebra_vxlan_if_vni_del(struct interface *ifp, vni_t vni);
extern int zebra_vxlan_if_del(struct interface *ifp);
+extern int zebra_vxlan_if_vni_table_add_update(struct interface *ifp,
+ struct hash *vni_table);
+extern int zebra_vxlan_if_vni_update(struct interface *ifp,
+ struct zebra_vxlan_vni *vni,
+ uint16_t chgflags);
extern int zebra_vxlan_if_update(struct interface *ifp, uint16_t chgflags);
+extern int zebra_vxlan_if_vni_add(struct interface *ifp,
+ struct zebra_vxlan_vni *vni);
extern int zebra_vxlan_if_add(struct interface *ifp);
#ifdef __cplusplus