Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[sfrench/cifs-2.6.git] / drivers / net / e1000 / e1000_main.c
index 4f37506ad3744656c86d102f63fb66aac2185876..13d57b0a88fa0936a02273b8e292baa6262ecca8 100644 (file)
@@ -3919,32 +3919,26 @@ e1000_clean(struct napi_struct *napi, int budget)
 {
        struct e1000_adapter *adapter = container_of(napi, struct e1000_adapter, napi);
        struct net_device *poll_dev = adapter->netdev;
-       int tx_cleaned = 0, work_done = 0;
+       int work_done = 0;
 
        /* Must NOT use netdev_priv macro here. */
        adapter = poll_dev->priv;
 
-       /* Keep link state information with original netdev */
-       if (!netif_carrier_ok(poll_dev))
-               goto quit_polling;
-
        /* e1000_clean is called per-cpu.  This lock protects
         * tx_ring[0] from being cleaned by multiple cpus
         * simultaneously.  A failure obtaining the lock means
         * tx_ring[0] is currently being cleaned anyway. */
        if (spin_trylock(&adapter->tx_queue_lock)) {
-               tx_cleaned = e1000_clean_tx_irq(adapter,
-                                               &adapter->tx_ring[0]);
+               e1000_clean_tx_irq(adapter,
+                                  &adapter->tx_ring[0]);
                spin_unlock(&adapter->tx_queue_lock);
        }
 
        adapter->clean_rx(adapter, &adapter->rx_ring[0],
                          &work_done, budget);
 
-       /* If no Tx and not enough Rx work done, exit the polling mode */
-       if ((!tx_cleaned && (work_done == 0)) ||
-          !netif_running(poll_dev)) {
-quit_polling:
+       /* If budget not fully consumed, exit the polling mode */
+       if (work_done < budget) {
                if (likely(adapter->itr_setting & 3))
                        e1000_set_itr(adapter);
                netif_rx_complete(poll_dev, napi);