aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ohci-hcd.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/host/ohci-hcd.c')
-rw-r--r--drivers/usb/host/ohci-hcd.c21
1 files changed, 20 insertions, 1 deletions
diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c
index f7c6ced2bc03..240c7f507541 100644
--- a/drivers/usb/host/ohci-hcd.c
+++ b/drivers/usb/host/ohci-hcd.c
@@ -1033,11 +1033,17 @@ MODULE_LICENSE ("GPL");
1033#define PS3_SYSTEM_BUS_DRIVER ps3_ohci_driver 1033#define PS3_SYSTEM_BUS_DRIVER ps3_ohci_driver
1034#endif 1034#endif
1035 1035
1036#ifdef CONFIG_USB_OHCI_HCD_SSB
1037#include "ohci-ssb.c"
1038#define SSB_OHCI_DRIVER ssb_ohci_driver
1039#endif
1040
1036#if !defined(PCI_DRIVER) && \ 1041#if !defined(PCI_DRIVER) && \
1037 !defined(PLATFORM_DRIVER) && \ 1042 !defined(PLATFORM_DRIVER) && \
1038 !defined(OF_PLATFORM_DRIVER) && \ 1043 !defined(OF_PLATFORM_DRIVER) && \
1039 !defined(SA1111_DRIVER) && \ 1044 !defined(SA1111_DRIVER) && \
1040 !defined(PS3_SYSTEM_BUS_DRIVER) 1045 !defined(PS3_SYSTEM_BUS_DRIVER) && \
1046 !defined(SSB_OHCI_DRIVER)
1041#error "missing bus glue for ohci-hcd" 1047#error "missing bus glue for ohci-hcd"
1042#endif 1048#endif
1043 1049
@@ -1082,10 +1088,20 @@ static int __init ohci_hcd_mod_init(void)
1082 goto error_pci; 1088 goto error_pci;
1083#endif 1089#endif
1084 1090
1091#ifdef SSB_OHCI_DRIVER
1092 retval = ssb_driver_register(&SSB_OHCI_DRIVER);
1093 if (retval)
1094 goto error_ssb;
1095#endif
1096
1085 return retval; 1097 return retval;
1086 1098
1087 /* Error path */ 1099 /* Error path */
1100#ifdef SSB_OHCI_DRIVER
1101 error_ssb:
1102#endif
1088#ifdef PCI_DRIVER 1103#ifdef PCI_DRIVER
1104 pci_unregister_driver(&PCI_DRIVER);
1089 error_pci: 1105 error_pci:
1090#endif 1106#endif
1091#ifdef SA1111_DRIVER 1107#ifdef SA1111_DRIVER
@@ -1110,6 +1126,9 @@ module_init(ohci_hcd_mod_init);
1110 1126
1111static void __exit ohci_hcd_mod_exit(void) 1127static void __exit ohci_hcd_mod_exit(void)
1112{ 1128{
1129#ifdef SSB_OHCI_DRIVER
1130 ssb_driver_unregister(&SSB_OHCI_DRIVER);
1131#endif
1113#ifdef PCI_DRIVER 1132#ifdef PCI_DRIVER
1114 pci_unregister_driver(&PCI_DRIVER); 1133 pci_unregister_driver(&PCI_DRIVER);
1115#endif 1134#endif