Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 45047
b: refs/heads/master
c: 44ade17
h: refs/heads/master
i:
  45045: 72756b5
  45043: 7f1f155
  45039: 8db77da
v: v3
  • Loading branch information
Stephen Hemminger authored and Jeff Garzik committed Dec 26, 2006
1 parent efbf73e commit acfd9a0
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 25d82d7a2fc20cc4be414d738139594dc0adf179
refs/heads/master: 44ade178249fe53d055fd92113eaa271e06acddd
25 changes: 25 additions & 0 deletions trunk/drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -3638,6 +3638,29 @@ static int sky2_resume(struct pci_dev *pdev)
out:
return err;
}

/* BIOS resume runs after device (it's a bug in PM)
* as a temporary workaround on suspend/resume leave MSI disabled
*/
static int sky2_suspend_late(struct pci_dev *pdev, pm_message_t state)
{
struct sky2_hw *hw = pci_get_drvdata(pdev);

free_irq(pdev->irq, hw);
if (hw->msi) {
pci_disable_msi(pdev);
hw->msi = 0;
}
return 0;
}

static int sky2_resume_early(struct pci_dev *pdev)
{
struct sky2_hw *hw = pci_get_drvdata(pdev);
struct net_device *dev = hw->dev[0];

return request_irq(pdev->irq, sky2_intr, IRQF_SHARED, dev->name, hw);
}
#endif

static struct pci_driver sky2_driver = {
Expand All @@ -3648,6 +3671,8 @@ static struct pci_driver sky2_driver = {
#ifdef CONFIG_PM
.suspend = sky2_suspend,
.resume = sky2_resume,
.suspend_late = sky2_suspend_late,
.resume_early = sky2_resume_early,
#endif
};

Expand Down

0 comments on commit acfd9a0

Please sign in to comment.