aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/e1000e
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/e1000e')
-rw-r--r--drivers/net/e1000e/e1000.h1
-rw-r--r--drivers/net/e1000e/ethtool.c1
-rw-r--r--drivers/net/e1000e/netdev.c12
3 files changed, 3 insertions, 11 deletions
diff --git a/drivers/net/e1000e/e1000.h b/drivers/net/e1000e/e1000.h
index c2ec095d2163..118bdf483593 100644
--- a/drivers/net/e1000e/e1000.h
+++ b/drivers/net/e1000e/e1000.h
@@ -279,7 +279,6 @@ struct e1000_adapter {
279 279
280 struct napi_struct napi; 280 struct napi_struct napi;
281 281
282 unsigned long tx_queue_len;
283 unsigned int restart_queue; 282 unsigned int restart_queue;
284 u32 txd_cmd; 283 u32 txd_cmd;
285 284
diff --git a/drivers/net/e1000e/ethtool.c b/drivers/net/e1000e/ethtool.c
index b33e3cbe9ab0..983493f2330c 100644
--- a/drivers/net/e1000e/ethtool.c
+++ b/drivers/net/e1000e/ethtool.c
@@ -31,6 +31,7 @@
31#include <linux/netdevice.h> 31#include <linux/netdevice.h>
32#include <linux/ethtool.h> 32#include <linux/ethtool.h>
33#include <linux/pci.h> 33#include <linux/pci.h>
34#include <linux/slab.h>
34#include <linux/delay.h> 35#include <linux/delay.h>
35 36
36#include "e1000.h" 37#include "e1000.h"
diff --git a/drivers/net/e1000e/netdev.c b/drivers/net/e1000e/netdev.c
index 88d54d3efcef..cfd09cea7214 100644
--- a/drivers/net/e1000e/netdev.c
+++ b/drivers/net/e1000e/netdev.c
@@ -36,6 +36,7 @@
36#include <linux/netdevice.h> 36#include <linux/netdevice.h>
37#include <linux/tcp.h> 37#include <linux/tcp.h>
38#include <linux/ipv6.h> 38#include <linux/ipv6.h>
39#include <linux/slab.h>
39#include <net/checksum.h> 40#include <net/checksum.h>
40#include <net/ip6_checksum.h> 41#include <net/ip6_checksum.h>
41#include <linux/mii.h> 42#include <linux/mii.h>
@@ -2289,8 +2290,6 @@ static void e1000_configure_tx(struct e1000_adapter *adapter)
2289 ew32(TCTL, tctl); 2290 ew32(TCTL, tctl);
2290 2291
2291 e1000e_config_collision_dist(hw); 2292 e1000e_config_collision_dist(hw);
2292
2293 adapter->tx_queue_len = adapter->netdev->tx_queue_len;
2294} 2293}
2295 2294
2296/** 2295/**
@@ -2877,7 +2876,6 @@ void e1000e_down(struct e1000_adapter *adapter)
2877 del_timer_sync(&adapter->watchdog_timer); 2876 del_timer_sync(&adapter->watchdog_timer);
2878 del_timer_sync(&adapter->phy_info_timer); 2877 del_timer_sync(&adapter->phy_info_timer);
2879 2878
2880 netdev->tx_queue_len = adapter->tx_queue_len;
2881 netif_carrier_off(netdev); 2879 netif_carrier_off(netdev);
2882 adapter->link_speed = 0; 2880 adapter->link_speed = 0;
2883 adapter->link_duplex = 0; 2881 adapter->link_duplex = 0;
@@ -3588,21 +3586,15 @@ static void e1000_watchdog_task(struct work_struct *work)
3588 "link gets many collisions.\n"); 3586 "link gets many collisions.\n");
3589 } 3587 }
3590 3588
3591 /* 3589 /* adjust timeout factor according to speed/duplex */
3592 * tweak tx_queue_len according to speed/duplex
3593 * and adjust the timeout factor
3594 */
3595 netdev->tx_queue_len = adapter->tx_queue_len;
3596 adapter->tx_timeout_factor = 1; 3590 adapter->tx_timeout_factor = 1;
3597 switch (adapter->link_speed) { 3591 switch (adapter->link_speed) {
3598 case SPEED_10: 3592 case SPEED_10:
3599 txb2b = 0; 3593 txb2b = 0;
3600 netdev->tx_queue_len = 10;
3601 adapter->tx_timeout_factor = 16; 3594 adapter->tx_timeout_factor = 16;
3602 break; 3595 break;
3603 case SPEED_100: 3596 case SPEED_100:
3604 txb2b = 0; 3597 txb2b = 0;
3605 netdev->tx_queue_len = 100;
3606 adapter->tx_timeout_factor = 10; 3598 adapter->tx_timeout_factor = 10;
3607 break; 3599 break;
3608 } 3600 }