[PATCH] b44: fix suspend/resume
authorPavel Machek <pavel@ucw.cz>
Fri, 28 Oct 2005 22:14:47 +0000 (15:14 -0700)
committerJeff Garzik <jgarzik@pobox.com>
Fri, 28 Oct 2005 23:06:43 +0000 (19:06 -0400)
Fix suspend/resume on b44 by freeing/reacquiring irq.  Otherwise it hangs
on resume.

Signed-off-by: Pavel Machek <pavel@suse.cz>
Cc: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
drivers/net/b44.c

index 5485e3b1cd353c8ec76e72bec3923af6caec1de9..0ee3e27969c6f921ad3dbfe990c48d62572996e9 100644 (file)
@@ -2041,6 +2041,8 @@ static int b44_suspend(struct pci_dev *pdev, pm_message_t state)
        b44_free_rings(bp);
 
        spin_unlock_irq(&bp->lock);
+
+       free_irq(dev->irq, dev);
        pci_disable_device(pdev);
        return 0;
 }
@@ -2057,6 +2059,9 @@ static int b44_resume(struct pci_dev *pdev)
        if (!netif_running(dev))
                return 0;
 
+       if (request_irq(dev->irq, b44_interrupt, SA_SHIRQ, dev->name, dev))
+               printk(KERN_ERR PFX "%s: request_irq failed\n", dev->name);
+
        spin_lock_irq(&bp->lock);
 
        b44_init_rings(bp);