diff options
Diffstat (limited to 'drivers/net/e1000')
-rw-r--r-- | drivers/net/e1000/e1000_main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c index ef12931d302a..6a46ceed9436 100644 --- a/drivers/net/e1000/e1000_main.c +++ b/drivers/net/e1000/e1000_main.c | |||
@@ -3834,7 +3834,6 @@ static bool e1000_clean_tx_irq(struct e1000_adapter *adapter, | |||
3834 | struct e1000_buffer *buffer_info; | 3834 | struct e1000_buffer *buffer_info; |
3835 | unsigned int i, eop; | 3835 | unsigned int i, eop; |
3836 | unsigned int count = 0; | 3836 | unsigned int count = 0; |
3837 | bool cleaned = false; | ||
3838 | unsigned int total_tx_bytes=0, total_tx_packets=0; | 3837 | unsigned int total_tx_bytes=0, total_tx_packets=0; |
3839 | 3838 | ||
3840 | i = tx_ring->next_to_clean; | 3839 | i = tx_ring->next_to_clean; |
@@ -3843,7 +3842,8 @@ static bool e1000_clean_tx_irq(struct e1000_adapter *adapter, | |||
3843 | 3842 | ||
3844 | while ((eop_desc->upper.data & cpu_to_le32(E1000_TXD_STAT_DD)) && | 3843 | while ((eop_desc->upper.data & cpu_to_le32(E1000_TXD_STAT_DD)) && |
3845 | (count < tx_ring->count)) { | 3844 | (count < tx_ring->count)) { |
3846 | for (cleaned = false; !cleaned; count++) { | 3845 | bool cleaned = false; |
3846 | for ( ; !cleaned; count++) { | ||
3847 | tx_desc = E1000_TX_DESC(*tx_ring, i); | 3847 | tx_desc = E1000_TX_DESC(*tx_ring, i); |
3848 | buffer_info = &tx_ring->buffer_info[i]; | 3848 | buffer_info = &tx_ring->buffer_info[i]; |
3849 | cleaned = (i == eop); | 3849 | cleaned = (i == eop); |
@@ -3871,7 +3871,7 @@ static bool e1000_clean_tx_irq(struct e1000_adapter *adapter, | |||
3871 | tx_ring->next_to_clean = i; | 3871 | tx_ring->next_to_clean = i; |
3872 | 3872 | ||
3873 | #define TX_WAKE_THRESHOLD 32 | 3873 | #define TX_WAKE_THRESHOLD 32 |
3874 | if (unlikely(cleaned && netif_carrier_ok(netdev) && | 3874 | if (unlikely(count && netif_carrier_ok(netdev) && |
3875 | E1000_DESC_UNUSED(tx_ring) >= TX_WAKE_THRESHOLD)) { | 3875 | E1000_DESC_UNUSED(tx_ring) >= TX_WAKE_THRESHOLD)) { |
3876 | /* Make sure that anybody stopping the queue after this | 3876 | /* Make sure that anybody stopping the queue after this |
3877 | * sees the new next_to_clean. | 3877 | * sees the new next_to_clean. |