diff options
Diffstat (limited to 'drivers/net/igbvf/netdev.c')
-rw-r--r-- | drivers/net/igbvf/netdev.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/drivers/net/igbvf/netdev.c b/drivers/net/igbvf/netdev.c index a77afd8a14bb..1b1edad1eb5e 100644 --- a/drivers/net/igbvf/netdev.c +++ b/drivers/net/igbvf/netdev.c | |||
@@ -35,6 +35,7 @@ | |||
35 | #include <linux/netdevice.h> | 35 | #include <linux/netdevice.h> |
36 | #include <linux/tcp.h> | 36 | #include <linux/tcp.h> |
37 | #include <linux/ipv6.h> | 37 | #include <linux/ipv6.h> |
38 | #include <linux/slab.h> | ||
38 | #include <net/checksum.h> | 39 | #include <net/checksum.h> |
39 | #include <net/ip6_checksum.h> | 40 | #include <net/ip6_checksum.h> |
40 | #include <linux/mii.h> | 41 | #include <linux/mii.h> |
@@ -1304,8 +1305,6 @@ static void igbvf_configure_tx(struct igbvf_adapter *adapter) | |||
1304 | 1305 | ||
1305 | /* enable Report Status bit */ | 1306 | /* enable Report Status bit */ |
1306 | adapter->txd_cmd |= E1000_ADVTXD_DCMD_RS; | 1307 | adapter->txd_cmd |= E1000_ADVTXD_DCMD_RS; |
1307 | |||
1308 | adapter->tx_queue_len = adapter->netdev->tx_queue_len; | ||
1309 | } | 1308 | } |
1310 | 1309 | ||
1311 | /** | 1310 | /** |
@@ -1524,7 +1523,6 @@ void igbvf_down(struct igbvf_adapter *adapter) | |||
1524 | 1523 | ||
1525 | del_timer_sync(&adapter->watchdog_timer); | 1524 | del_timer_sync(&adapter->watchdog_timer); |
1526 | 1525 | ||
1527 | netdev->tx_queue_len = adapter->tx_queue_len; | ||
1528 | netif_carrier_off(netdev); | 1526 | netif_carrier_off(netdev); |
1529 | 1527 | ||
1530 | /* record the stats before reset*/ | 1528 | /* record the stats before reset*/ |
@@ -1857,21 +1855,15 @@ static void igbvf_watchdog_task(struct work_struct *work) | |||
1857 | &adapter->link_duplex); | 1855 | &adapter->link_duplex); |
1858 | igbvf_print_link_info(adapter); | 1856 | igbvf_print_link_info(adapter); |
1859 | 1857 | ||
1860 | /* | 1858 | /* adjust timeout factor according to speed/duplex */ |
1861 | * tweak tx_queue_len according to speed/duplex | ||
1862 | * and adjust the timeout factor | ||
1863 | */ | ||
1864 | netdev->tx_queue_len = adapter->tx_queue_len; | ||
1865 | adapter->tx_timeout_factor = 1; | 1859 | adapter->tx_timeout_factor = 1; |
1866 | switch (adapter->link_speed) { | 1860 | switch (adapter->link_speed) { |
1867 | case SPEED_10: | 1861 | case SPEED_10: |
1868 | txb2b = 0; | 1862 | txb2b = 0; |
1869 | netdev->tx_queue_len = 10; | ||
1870 | adapter->tx_timeout_factor = 16; | 1863 | adapter->tx_timeout_factor = 16; |
1871 | break; | 1864 | break; |
1872 | case SPEED_100: | 1865 | case SPEED_100: |
1873 | txb2b = 0; | 1866 | txb2b = 0; |
1874 | netdev->tx_queue_len = 100; | ||
1875 | /* maybe add some timeout factor ? */ | 1867 | /* maybe add some timeout factor ? */ |
1876 | break; | 1868 | break; |
1877 | } | 1869 | } |