aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/ip
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/ip')
-rw-r--r--src/vnet/ip/ip.api1
-rw-r--r--src/vnet/ip/ip_api.c5
2 files changed, 6 insertions, 0 deletions
diff --git a/src/vnet/ip/ip.api b/src/vnet/ip/ip.api
index f26d79436a5..4b7019f087e 100644
--- a/src/vnet/ip/ip.api
+++ b/src/vnet/ip/ip.api
@@ -397,6 +397,7 @@ autoreply define ip_add_del_route
u8 is_multipath;
u8 is_resolve_host;
u8 is_resolve_attached;
+ u8 is_l2_bridged;
/* Is last/not-last message in group of multiple add/del messages. */
u8 not_last;
u8 next_hop_weight;
diff --git a/src/vnet/ip/ip_api.c b/src/vnet/ip/ip_api.c
index 6981c84cb0e..c34ec57dc84 100644
--- a/src/vnet/ip/ip_api.c
+++ b/src/vnet/ip/ip_api.c
@@ -769,6 +769,7 @@ add_del_route_t_handler (u8 is_multipath,
u8 is_resolve_attached,
u8 is_interface_rx,
u8 is_rpf_id,
+ u8 is_l2_bridged,
u32 fib_index,
const fib_prefix_t * prefix,
dpo_proto_t next_hop_proto,
@@ -806,6 +807,8 @@ add_del_route_t_handler (u8 is_multipath,
path.frp_local_label = next_hop_via_label;
path.frp_eos = MPLS_NON_EOS;
}
+ if (is_l2_bridged)
+ path.frp_proto = DPO_PROTO_ETHERNET;
if (is_resolve_host)
path_flags |= FIB_ROUTE_PATH_RESOLVE_VIA_HOST;
if (is_resolve_attached)
@@ -1043,6 +1046,7 @@ ip4_add_del_route_t_handler (vl_api_ip_add_del_route_t * mp)
mp->classify_table_index,
mp->is_resolve_host,
mp->is_resolve_attached, 0, 0,
+ mp->is_l2_bridged,
fib_index, &pfx, DPO_PROTO_IP4,
&nh,
ntohl (mp->next_hop_sw_if_index),
@@ -1102,6 +1106,7 @@ ip6_add_del_route_t_handler (vl_api_ip_add_del_route_t * mp)
mp->classify_table_index,
mp->is_resolve_host,
mp->is_resolve_attached, 0, 0,
+ mp->is_l2_bridged,
fib_index, &pfx, DPO_PROTO_IP6,
&nh, ntohl (mp->next_hop_sw_if_index),
next_hop_fib_index,