aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ohci-pci.c
diff options
context:
space:
mode:
authorAleksey Gorelov <dared1st@yahoo.com>2006-08-08 20:24:08 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2006-09-27 14:58:54 -0400
commit64a21d025d3a979a8715f2ec7acabca7b5406c8a (patch)
treee3cbcef560d848e177cddde6d093aa2411cddd53 /drivers/usb/host/ohci-pci.c
parenta94da8971e836f32315f8832b0bf3e88bee9efae (diff)
USB: Properly unregister reboot notifier in case of failure in ehci hcd
If some problem occurs during ehci startup, for instance, request_irq fails, echi hcd driver tries it best to cleanup, but fails to unregister reboot notifier, which in turn leads to crash on reboot/poweroff. The following patch resolves this problem by not using reboot notifiers anymore, but instead making ehci/ohci driver get its own shutdown method. For PCI, it is done through pci glue, for everything else through platform driver glue. One downside: sa1111 does not use platform driver stuff, and does not have its own shutdown hook, so no 'shutdown' is called for it now. I'm not sure if it is really necessary on that platform, though. Signed-off-by: Aleks Gorelov <dared1st@yahoo.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/ohci-pci.c')
-rw-r--r--drivers/usb/host/ohci-pci.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/host/ohci-pci.c b/drivers/usb/host/ohci-pci.c
index ef874443aa9f..3732db7d68eb 100644
--- a/drivers/usb/host/ohci-pci.c
+++ b/drivers/usb/host/ohci-pci.c
@@ -177,6 +177,7 @@ static const struct hc_driver ohci_pci_hc_driver = {
177 .reset = ohci_pci_reset, 177 .reset = ohci_pci_reset,
178 .start = ohci_pci_start, 178 .start = ohci_pci_start,
179 .stop = ohci_stop, 179 .stop = ohci_stop,
180 .shutdown = ohci_shutdown,
180 181
181#ifdef CONFIG_PM 182#ifdef CONFIG_PM
182 /* these suspend/resume entries are for upstream PCI glue ONLY */ 183 /* these suspend/resume entries are for upstream PCI glue ONLY */
@@ -232,6 +233,8 @@ static struct pci_driver ohci_pci_driver = {
232 .suspend = usb_hcd_pci_suspend, 233 .suspend = usb_hcd_pci_suspend,
233 .resume = usb_hcd_pci_resume, 234 .resume = usb_hcd_pci_resume,
234#endif 235#endif
236
237 .shutdown = usb_hcd_pci_shutdown,
235}; 238};
236 239
237 240