summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2019-09-27 15:46:22 +0200
committerPhilippe Guibert <philippe.guibert@6wind.com>2020-05-18 14:11:03 +0200
commitf8ed2c5420106314a940cb67264494e0110fc4c0 (patch)
tree1770e658098f03fa13c1136a659582955ff604c2
parent388d5b438e22cddc6740e362763c0922edbb242a (diff)
zebra: fdb and neighbor table are read for all zns
all network namespaces are read so as to collect interesting fdb and neighbor tables for EVPN. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
-rw-r--r--zebra/zebra_vxlan.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/zebra/zebra_vxlan.c b/zebra/zebra_vxlan.c
index a3f70d585c..9447048706 100644
--- a/zebra/zebra_vxlan.c
+++ b/zebra/zebra_vxlan.c
@@ -9744,6 +9744,21 @@ stream_failure:
return;
}
+static int macfdb_read_zns(struct zebra_ns *zns,
+ void *_in_param __attribute__((unused)),
+ void **out_param __attribute__((unused)))
+{
+ macfdb_read(zns);
+ return ZNS_WALK_CONTINUE;
+}
+
+static int neigh_read_zns(struct zebra_ns *zns,
+ void *_in_param __attribute__((unused)),
+ void **out_param __attribute__((unused)))
+{
+ neigh_read(zns);
+ return ZNS_WALK_CONTINUE;
+}
/*
* Handle message from client to learn (or stop learning) about VNIs and MACs.
@@ -9793,10 +9808,10 @@ void zebra_vxlan_advertise_all_vni(ZAPI_HANDLER_ARGS)
NULL);
/* Read the MAC FDB */
- macfdb_read(zvrf->zns);
+ zebra_ns_list_walk(macfdb_read_zns, NULL, NULL);
/* Read neighbors */
- neigh_read(zvrf->zns);
+ zebra_ns_list_walk(neigh_read_zns, NULL, NULL);
} else {
/* Cleanup VTEPs for all VNIs - uninstall from
* kernel and free entries.