Commit 119b7c92 authored by Benjamin Herrenschmidt's avatar Benjamin Herrenschmidt Committed by Linus Torvalds

[PATCH] remove some PowerMac cruft from USB

The PowerMac specific sleep code in the OHCI USB driver used to call
disable/enable irq, which is no longer necessary and actually clashes with
the calls to free/request_irq that the common OHCI code now does, thus
causing WARN_ON's to trigger each time a PowerBook is woken up from sleep.
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent c92ac81e
......@@ -121,10 +121,7 @@ static int ohci_pci_suspend (struct usb_hcd *hcd, u32 state)
msleep (100);
#ifdef CONFIG_PMAC_PBOOK
if (_machine == _MACH_Pmac)
disable_irq ((to_pci_dev(hcd->self.controller))->irq);
{
if (_machine == _MACH_Pmac) {
struct device_node *of_node;
/* Disable USB PAD & cell clock */
......@@ -132,7 +129,7 @@ static int ohci_pci_suspend (struct usb_hcd *hcd, u32 state)
if (of_node)
pmac_call_feature(PMAC_FTR_USB_ENABLE, of_node, 0, 0);
}
#endif
#endif /* CONFIG_PMAC_PBOOK */
return 0;
}
......@@ -143,7 +140,7 @@ static int ohci_pci_resume (struct usb_hcd *hcd)
int retval = 0;
#ifdef CONFIG_PMAC_PBOOK
{
if (_machine == _MACH_Pmac) {
struct device_node *of_node;
/* Re-enable USB PAD & cell clock */
......@@ -151,7 +148,7 @@ static int ohci_pci_resume (struct usb_hcd *hcd)
if (of_node)
pmac_call_feature (PMAC_FTR_USB_ENABLE, of_node, 0, 1);
}
#endif
#endif /* CONFIG_PMAC_PBOOK */
/* resume root hub */
if (time_before (jiffies, ohci->next_statechange))
......@@ -165,12 +162,6 @@ static int ohci_pci_resume (struct usb_hcd *hcd)
usb_unlock_device (hcd->self.root_hub);
#endif
if (retval == 0) {
#ifdef CONFIG_PMAC_PBOOK
if (_machine == _MACH_Pmac)
enable_irq (to_pci_dev(hcd->self.controller)->irq);
#endif
}
return retval;
}
......
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