summaryrefslogtreecommitdiffstats
path: root/src/vnet/gre/interface.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/gre/interface.c')
-rw-r--r--src/vnet/gre/interface.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/vnet/gre/interface.c b/src/vnet/gre/interface.c
index 6efa3da13b8..f5a1bde527f 100644
--- a/src/vnet/gre/interface.c
+++ b/src/vnet/gre/interface.c
@@ -377,7 +377,12 @@ vnet_gre_tunnel_add (vnet_gre_tunnel_add_del_args_t * a,
}
/* Set GRE tunnel interface output node (not used for L3 payload) */
- vnet_set_interface_output_node (vnm, hw_if_index, gre_encap_node.index);
+ if (GRE_TUNNEL_TYPE_ERSPAN == t->type)
+ vnet_set_interface_output_node (vnm, hw_if_index,
+ gre_erspan_encap_node.index);
+ else
+ vnet_set_interface_output_node (vnm, hw_if_index,
+ gre_teb_encap_node.index);
hi = vnet_get_hw_interface (vnm, hw_if_index);
sw_if_index = hi->sw_if_index;