diff options
author | Steven Luong <sluong@cisco.com> | 2019-08-30 10:49:44 -0700 |
---|---|---|
committer | Damjan Marion <dmarion@me.com> | 2019-09-03 19:40:53 +0000 |
commit | 08940a2cb8177ce6c89ba0e9146515978dc66560 (patch) | |
tree | 339fa2ada290cb4d6494c624d9166be9dee57872 /src/vnet | |
parent | fec95f8df7f17132ca9fdd122b7d3dab35f01daf (diff) |
tap: interface rx counter not increment correct
vlib_increment_combined_counter takes sw_if_index, not hw_if_index. Using
hw_if_index may work as long as there is no subinterface created to cause
hw_if_index and sw_if_index to differ.
Type: fix
Ticket: VPP-1759
Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I6db042186eeeacf32250f7ef261af8cd6f5ce56e
(cherry picked from commit efa119db3910e77f79eb005c67f8c01b473b40a1)
Diffstat (limited to 'src/vnet')
-rw-r--r-- | src/vnet/devices/virtio/node.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vnet/devices/virtio/node.c b/src/vnet/devices/virtio/node.c index 3b218abdbb7..8441250ff1d 100644 --- a/src/vnet/devices/virtio/node.c +++ b/src/vnet/devices/virtio/node.c @@ -357,7 +357,7 @@ virtio_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, - vif->hw_if_index, n_rx_packets, + vif->sw_if_index, n_rx_packets, n_rx_bytes); refill: |