aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/gbp/gbp_endpoint.c17
-rw-r--r--src/plugins/mactime/builtins.c2
-rw-r--r--src/plugins/mactime/mactime.c2
3 files changed, 14 insertions, 7 deletions
diff --git a/src/plugins/gbp/gbp_endpoint.c b/src/plugins/gbp/gbp_endpoint.c
index e1a810cf222..9cc69d01277 100644
--- a/src/plugins/gbp/gbp_endpoint.c
+++ b/src/plugins/gbp/gbp_endpoint.c
@@ -30,6 +30,8 @@
#include <vnet/l2/l2_fib.h>
#include <vnet/fib/fib_table.h>
#include <vnet/ip-neighbor/ip_neighbor.h>
+#include <vnet/ip-neighbor/ip4_neighbor.h>
+#include <vnet/ip-neighbor/ip6_neighbor.h>
#include <vnet/fib/fib_walk.h>
#include <vnet/vxlan-gbp/vxlan_gbp.h>
@@ -768,11 +770,16 @@ gbb_endpoint_fwd_recalc (gbp_endpoint_t * ge)
{
gbp_endpoint_add_itf (gbp_itf_get_sw_if_index (gef->gef_itf),
gei);
- ip_neighbor_advertise (vlib_get_main (),
- (FIB_PROTOCOL_IP4 == pfx->fp_proto ?
- IP46_TYPE_IP4 :
- IP46_TYPE_IP6),
- &pfx->fp_addr, gg->gg_uplink_sw_if_index);
+ if (FIB_PROTOCOL_IP4 == pfx->fp_proto)
+ ip4_neighbor_advertise (vlib_get_main (),
+ vnet_get_main (),
+ gg->gg_uplink_sw_if_index,
+ &pfx->fp_addr.ip4);
+ else
+ ip6_neighbor_advertise (vlib_get_main (),
+ vnet_get_main (),
+ gg->gg_uplink_sw_if_index,
+ &pfx->fp_addr.ip6);
}
}
}
diff --git a/src/plugins/mactime/builtins.c b/src/plugins/mactime/builtins.c
index e90ac661a13..1525ab66ae7 100644
--- a/src/plugins/mactime/builtins.c
+++ b/src/plugins/mactime/builtins.c
@@ -35,7 +35,7 @@ handle_get_mactime (http_builtin_method_type_t reqtype,
/* Walk all ip4 neighbours on all interfaces */
vec_reset_length (mm->arp_cache_copy);
- ip_neighbor_walk (IP46_TYPE_IP4, ~0, mactime_ip_neighbor_copy, mm);
+ ip_neighbor_walk (AF_IP4, ~0, mactime_ip_neighbor_copy, mm);
now = clib_timebase_now (&mm->timebase);
diff --git a/src/plugins/mactime/mactime.c b/src/plugins/mactime/mactime.c
index d41853447c1..66df70bca2f 100644
--- a/src/plugins/mactime/mactime.c
+++ b/src/plugins/mactime/mactime.c
@@ -561,7 +561,7 @@ show_mactime_command_fn (vlib_main_t * vm,
vec_reset_length (mm->arp_cache_copy);
/* Walk all ip4 neighbours on all interfaces */
- ip_neighbor_walk (IP46_TYPE_IP4, ~0, mactime_ip_neighbor_copy, mm);
+ ip_neighbor_walk (AF_IP4, ~0, mactime_ip_neighbor_copy, mm);
now = clib_timebase_now (&mm->timebase);