VPP-314: Vxlan wrong name of decap node 02/2302/1
authorJohn Lo <loj@cisco.com>
Tue, 9 Aug 2016 23:20:51 +0000 (19:20 -0400)
committerJohn Lo <loj@cisco.com>
Tue, 9 Aug 2016 23:20:51 +0000 (19:20 -0400)
Fix VXLAN decap node counter update using the correct node index.

Change-Id: Iebfd2bfd97747bc6d0758f4c5829e23ef9899d74
Signed-off-by: John Lo <loj@cisco.com>
vnet/vnet/vxlan/decap.c

index 899b331..2b74ce2 100644 (file)
@@ -19,7 +19,8 @@
 #include <vnet/pg/pg.h>
 #include <vnet/vxlan/vxlan.h>
 
-vlib_node_registration_t vxlan_input_node;
+vlib_node_registration_t vxlan4_input_node;
+vlib_node_registration_t vxlan6_input_node;
 
 typedef struct {
   u32 next_index;
@@ -493,7 +494,8 @@ vxlan_input (vlib_main_t * vm,
       vlib_put_next_frame (vm, node, next_index, n_left_to_next);
     }
   /* Do we still need this now that tunnel tx stats is kept? */
-  vlib_node_increment_counter (vm, vxlan_input_node.index,
+  vlib_node_increment_counter (vm, is_ip4? 
+                              vxlan4_input_node.index:vxlan6_input_node.index,
                                VXLAN_ERROR_DECAPSULATED, 
                                pkts_decapsulated);