Commit c43bc57e authored by Jesse Brandeburg's avatar Jesse Brandeburg Committed by Jeff Garzik

e1000e: fix drv load issues

a few people seem to have problems maintaining gigabit link
and it was root caused to an interaction between the managability
firmware on the host and the driver, not communicating.

The form of communication they use is the drv_load bit.
Signed-off-by: default avatarJesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
parent 10aa4c04
...@@ -2444,7 +2444,7 @@ void e1000e_reset(struct e1000_adapter *adapter) ...@@ -2444,7 +2444,7 @@ void e1000e_reset(struct e1000_adapter *adapter)
* For parts with AMT enabled, let the firmware know * For parts with AMT enabled, let the firmware know
* that the network interface is in control * that the network interface is in control
*/ */
if ((adapter->flags & FLAG_HAS_AMT) && e1000e_check_mng_mode(hw)) if (adapter->flags & FLAG_HAS_AMT)
e1000_get_hw_control(adapter); e1000_get_hw_control(adapter);
ew32(WUC, 0); ew32(WUC, 0);
...@@ -2634,8 +2634,7 @@ static int e1000_open(struct net_device *netdev) ...@@ -2634,8 +2634,7 @@ static int e1000_open(struct net_device *netdev)
* If AMT is enabled, let the firmware know that the network * If AMT is enabled, let the firmware know that the network
* interface is now open * interface is now open
*/ */
if ((adapter->flags & FLAG_HAS_AMT) && if (adapter->flags & FLAG_HAS_AMT)
e1000e_check_mng_mode(&adapter->hw))
e1000_get_hw_control(adapter); e1000_get_hw_control(adapter);
/* /*
...@@ -2713,8 +2712,7 @@ static int e1000_close(struct net_device *netdev) ...@@ -2713,8 +2712,7 @@ static int e1000_close(struct net_device *netdev)
* If AMT is enabled, let the firmware know that the network * If AMT is enabled, let the firmware know that the network
* interface is now closed * interface is now closed
*/ */
if ((adapter->flags & FLAG_HAS_AMT) && if (adapter->flags & FLAG_HAS_AMT)
e1000e_check_mng_mode(&adapter->hw))
e1000_release_hw_control(adapter); e1000_release_hw_control(adapter);
return 0; return 0;
...@@ -4030,7 +4028,7 @@ static int e1000_resume(struct pci_dev *pdev) ...@@ -4030,7 +4028,7 @@ static int e1000_resume(struct pci_dev *pdev)
* is up. For all other cases, let the f/w know that the h/w is now * is up. For all other cases, let the f/w know that the h/w is now
* under the control of the driver. * under the control of the driver.
*/ */
if (!(adapter->flags & FLAG_HAS_AMT) || !e1000e_check_mng_mode(&adapter->hw)) if (!(adapter->flags & FLAG_HAS_AMT))
e1000_get_hw_control(adapter); e1000_get_hw_control(adapter);
return 0; return 0;
...@@ -4149,8 +4147,7 @@ static void e1000_io_resume(struct pci_dev *pdev) ...@@ -4149,8 +4147,7 @@ static void e1000_io_resume(struct pci_dev *pdev)
* is up. For all other cases, let the f/w know that the h/w is now * is up. For all other cases, let the f/w know that the h/w is now
* under the control of the driver. * under the control of the driver.
*/ */
if (!(adapter->flags & FLAG_HAS_AMT) || if (!(adapter->flags & FLAG_HAS_AMT))
!e1000e_check_mng_mode(&adapter->hw))
e1000_get_hw_control(adapter); e1000_get_hw_control(adapter);
} }
...@@ -4505,8 +4502,7 @@ static int __devinit e1000_probe(struct pci_dev *pdev, ...@@ -4505,8 +4502,7 @@ static int __devinit e1000_probe(struct pci_dev *pdev,
* is up. For all other cases, let the f/w know that the h/w is now * is up. For all other cases, let the f/w know that the h/w is now
* under the control of the driver. * under the control of the driver.
*/ */
if (!(adapter->flags & FLAG_HAS_AMT) || if (!(adapter->flags & FLAG_HAS_AMT))
!e1000e_check_mng_mode(&adapter->hw))
e1000_get_hw_control(adapter); e1000_get_hw_control(adapter);
/* tell the stack to leave us alone until e1000_open() is called */ /* tell the stack to leave us alone until e1000_open() is called */
...@@ -4523,19 +4519,19 @@ static int __devinit e1000_probe(struct pci_dev *pdev, ...@@ -4523,19 +4519,19 @@ static int __devinit e1000_probe(struct pci_dev *pdev,
return 0; return 0;
err_register: err_register:
err_hw_init: if (!(adapter->flags & FLAG_HAS_AMT))
e1000_release_hw_control(adapter); e1000_release_hw_control(adapter);
err_eeprom: err_eeprom:
if (!e1000_check_reset_block(&adapter->hw)) if (!e1000_check_reset_block(&adapter->hw))
e1000_phy_hw_reset(&adapter->hw); e1000_phy_hw_reset(&adapter->hw);
err_hw_init:
if (adapter->hw.flash_address)
iounmap(adapter->hw.flash_address);
err_flashmap:
kfree(adapter->tx_ring); kfree(adapter->tx_ring);
kfree(adapter->rx_ring); kfree(adapter->rx_ring);
err_sw_init: err_sw_init:
if (adapter->hw.flash_address)
iounmap(adapter->hw.flash_address);
err_flashmap:
iounmap(adapter->hw.hw_addr); iounmap(adapter->hw.hw_addr);
err_ioremap: err_ioremap:
free_netdev(netdev); free_netdev(netdev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment