提交 3d1dd8cb 编写于 作者: A Auke Kok 提交者: Auke Kok

e1000: error out if we cannot enable PCI device on resume

Do not ignore errors returned by pci_enable_device, instead error out.
Signed-off-by: NAuke Kok <auke-jan.h.kok@intel.com>
上级 3fbbc72e
......@@ -4709,11 +4709,14 @@ e1000_resume(struct pci_dev *pdev)
{
struct net_device *netdev = pci_get_drvdata(pdev);
struct e1000_adapter *adapter = netdev_priv(netdev);
uint32_t manc, ret_val;
uint32_t manc, err;
pci_set_power_state(pdev, PCI_D0);
e1000_pci_restore_state(adapter);
ret_val = pci_enable_device(pdev);
if ((err = pci_enable_device(pdev))) {
printk(KERN_ERR "e1000: Cannot enable PCI device from suspend\n");
return err;
}
pci_set_master(pdev);
pci_enable_wake(pdev, PCI_D3hot, 0);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册