X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fplugins%2Fgbp%2Fgbp_endpoint.c;fp=src%2Fplugins%2Fgbp%2Fgbp_endpoint.c;h=9cc69d01277a16e32503d4e6eb7c6cde15ec5645;hb=dc617b8df442f3e25197ec64ffd58d11411b0470;hp=e1a810cf222bc2a52d680452424f79b4b8ed41d1;hpb=d01d2ce4498dae4cbcba65784babe91d56d4bae9;p=vpp.git 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 #include #include +#include +#include #include #include @@ -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); } } }