aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNarendra K <narendra_k@dell.com>2012-07-16 11:24:41 -0400
committerDavid S. Miller <davem@davemloft.net>2012-07-17 01:44:36 -0400
commit936597631dd310e220544dc5c6075d924efd39b2 (patch)
tree240cd109d3f6ecc017fef3e702dec530d1da6de5
parent2eebc1e188e9e45886ee00662519849339884d6d (diff)
ixgbevf: Prevent RX/TX statistics getting reset to zero
The commit 4197aa7bb81877ebb06e4f2cc1b5fea2da23a7bd implements 64 bit per ring statistics. But the driver resets the 'total_bytes' and 'total_packets' from RX and TX rings in the RX and TX interrupt handlers to zero. This results in statistics being lost and user space reporting RX and TX statistics as zero. This patch addresses the issue by preventing the resetting of RX and TX ring statistics to zero. Signed-off-by: Narendra K <narendra_k@dell.com> Tested-by: Sibai Li <sibai.li@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c b/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c
index f69ec4288b10..8b304a43a22d 100644
--- a/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c
+++ b/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c
@@ -969,8 +969,6 @@ static irqreturn_t ixgbevf_msix_clean_tx(int irq, void *data)
969 r_idx = find_first_bit(q_vector->txr_idx, adapter->num_tx_queues); 969 r_idx = find_first_bit(q_vector->txr_idx, adapter->num_tx_queues);
970 for (i = 0; i < q_vector->txr_count; i++) { 970 for (i = 0; i < q_vector->txr_count; i++) {
971 tx_ring = &(adapter->tx_ring[r_idx]); 971 tx_ring = &(adapter->tx_ring[r_idx]);
972 tx_ring->total_bytes = 0;
973 tx_ring->total_packets = 0;
974 ixgbevf_clean_tx_irq(adapter, tx_ring); 972 ixgbevf_clean_tx_irq(adapter, tx_ring);
975 r_idx = find_next_bit(q_vector->txr_idx, adapter->num_tx_queues, 973 r_idx = find_next_bit(q_vector->txr_idx, adapter->num_tx_queues,
976 r_idx + 1); 974 r_idx + 1);
@@ -994,16 +992,6 @@ static irqreturn_t ixgbevf_msix_clean_rx(int irq, void *data)
994 struct ixgbe_hw *hw = &adapter->hw; 992 struct ixgbe_hw *hw = &adapter->hw;
995 struct ixgbevf_ring *rx_ring; 993 struct ixgbevf_ring *rx_ring;
996 int r_idx; 994 int r_idx;
997 int i;
998
999 r_idx = find_first_bit(q_vector->rxr_idx, adapter->num_rx_queues);
1000 for (i = 0; i < q_vector->rxr_count; i++) {
1001 rx_ring = &(adapter->rx_ring[r_idx]);
1002 rx_ring->total_bytes = 0;
1003 rx_ring->total_packets = 0;
1004 r_idx = find_next_bit(q_vector->rxr_idx, adapter->num_rx_queues,
1005 r_idx + 1);
1006 }
1007 995
1008 if (!q_vector->rxr_count) 996 if (!q_vector->rxr_count)
1009 return IRQ_HANDLED; 997 return IRQ_HANDLED;