aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/ixgbe
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ethernet/intel/ixgbe')
-rw-r--r--drivers/net/ethernet/intel/ixgbe/ixgbe_main.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index ceab142bcf8a..a34ee7d63563 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -1794,7 +1794,7 @@ dma_sync:
1794 **/ 1794 **/
1795static bool ixgbe_clean_rx_irq(struct ixgbe_q_vector *q_vector, 1795static bool ixgbe_clean_rx_irq(struct ixgbe_q_vector *q_vector,
1796 struct ixgbe_ring *rx_ring, 1796 struct ixgbe_ring *rx_ring,
1797 int budget) 1797 const int budget)
1798{ 1798{
1799 unsigned int total_rx_bytes = 0, total_rx_packets = 0; 1799 unsigned int total_rx_bytes = 0, total_rx_packets = 0;
1800#ifdef IXGBE_FCOE 1800#ifdef IXGBE_FCOE
@@ -1845,7 +1845,6 @@ static bool ixgbe_clean_rx_irq(struct ixgbe_q_vector *q_vector,
1845 1845
1846 /* probably a little skewed due to removing CRC */ 1846 /* probably a little skewed due to removing CRC */
1847 total_rx_bytes += skb->len; 1847 total_rx_bytes += skb->len;
1848 total_rx_packets++;
1849 1848
1850 /* populate checksum, timestamp, VLAN, and protocol */ 1849 /* populate checksum, timestamp, VLAN, and protocol */
1851 ixgbe_process_skb_fields(rx_ring, rx_desc, skb); 1850 ixgbe_process_skb_fields(rx_ring, rx_desc, skb);
@@ -1878,8 +1877,8 @@ static bool ixgbe_clean_rx_irq(struct ixgbe_q_vector *q_vector,
1878 ixgbe_rx_skb(q_vector, skb); 1877 ixgbe_rx_skb(q_vector, skb);
1879 1878
1880 /* update budget accounting */ 1879 /* update budget accounting */
1881 budget--; 1880 total_rx_packets++;
1882 } while (likely(budget)); 1881 } while (likely(total_rx_packets < budget));
1883 1882
1884 u64_stats_update_begin(&rx_ring->syncp); 1883 u64_stats_update_begin(&rx_ring->syncp);
1885 rx_ring->stats.packets += total_rx_packets; 1884 rx_ring->stats.packets += total_rx_packets;
@@ -1891,7 +1890,7 @@ static bool ixgbe_clean_rx_irq(struct ixgbe_q_vector *q_vector,
1891 if (cleaned_count) 1890 if (cleaned_count)
1892 ixgbe_alloc_rx_buffers(rx_ring, cleaned_count); 1891 ixgbe_alloc_rx_buffers(rx_ring, cleaned_count);
1893 1892
1894 return !!budget; 1893 return (total_rx_packets < budget);
1895} 1894}
1896 1895
1897/** 1896/**