From: Steven Luong Date: Thu, 6 Aug 2020 19:22:53 +0000 (-0700) Subject: memif: wrong interface counter is incremented X-Git-Tag: v21.01-rc0~131 X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=35050289e6b5f6e2939b1d08ed058ab952468943;p=vpp.git memif: wrong interface counter is incremented vlib_increment_combined_counter takes sw_if_index, not hw_if_index. Type: fix Signed-off-by: Steven Luong Change-Id: Iecde2697ed490940f0eff796d28d15381405b895 --- diff --git a/src/plugins/memif/node.c b/src/plugins/memif/node.c index dd8f9ba597e..82a7cbc142c 100644 --- a/src/plugins/memif/node.c +++ b/src/plugins/memif/node.c @@ -509,7 +509,7 @@ memif_device_input_inline (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_increment_combined_counter (vnm->interface_main.combined_sw_if_counters + VNET_INTERFACE_COUNTER_RX, thread_index, - mif->hw_if_index, n_rx_packets, + mif->sw_if_index, n_rx_packets, n_rx_bytes); /* refill ring with empty buffers */ @@ -772,7 +772,7 @@ memif_device_input_zc_inline (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_increment_combined_counter (vnm->interface_main.combined_sw_if_counters + VNET_INTERFACE_COUNTER_RX, thread_index, - mif->hw_if_index, n_rx_packets, + mif->sw_if_index, n_rx_packets, n_rx_bytes); /* refill ring with empty buffers */