summaryrefslogtreecommitdiffstats
path: root/vnet/vnet/vxlan/vxlan.c
diff options
context:
space:
mode:
authorJohn Lo <loj@cisco.com>2016-01-19 17:27:17 -0500
committerJohn Lo <loj@cisco.com>2016-01-19 17:27:17 -0500
commit2d34374f7d2f624a4a66cf46d4d11e5b49808ada (patch)
treee32883ab9b8da5fa0c93d499694b7d025eb77ddd /vnet/vnet/vxlan/vxlan.c
parent52372b6c8e36401721a0533301e1ecdb30109424 (diff)
Enhance and fix packet trace for IP forwarding as follows:
1. Add fib index to IP6 forwarding trace. 2. Display adjacency index in IP forwarding trace. 3. Fix adjacency display for L3 to L2 forwarding such as BVI and VXLAN tunnel decap. 4. Setup VXLAN tunnel fib index properly for packet trace. Change-Id: I261fea5abf51e2550d24cdcee53887be2fdd08de Signed-off-by: John Lo <loj@cisco.com>
Diffstat (limited to 'vnet/vnet/vxlan/vxlan.c')
-rw-r--r--vnet/vnet/vxlan/vxlan.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/vnet/vnet/vxlan/vxlan.c b/vnet/vnet/vxlan/vxlan.c
index 316f8cb1907..28ed173c020 100644
--- a/vnet/vnet/vxlan/vxlan.c
+++ b/vnet/vnet/vxlan/vxlan.c
@@ -142,6 +142,7 @@ int vnet_vxlan_add_del_tunnel
vxlan_main_t * vxm = &vxlan_main;
vxlan_tunnel_t *t = 0;
vnet_main_t * vnm = vxm->vnet_main;
+ ip4_main_t * im4 = &ip4_main;
vnet_hw_interface_t * hi;
uword * p;
u32 hw_if_index = ~0;
@@ -231,6 +232,8 @@ int vnet_vxlan_add_del_tunnel
}
vnet_sw_interface_set_flags (vnm, sw_if_index,
VNET_SW_INTERFACE_FLAG_ADMIN_UP);
+ vec_validate (im4->fib_index_by_sw_if_index, sw_if_index);
+ im4->fib_index_by_sw_if_index[sw_if_index] = t->encap_fib_index;
}
else
{