diff options
Diffstat (limited to 'drivers/usb/host/ehci-hcd.c')
-rw-r--r-- | drivers/usb/host/ehci-hcd.c | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c index 6bf909e1adf0..a74056488234 100644 --- a/drivers/usb/host/ehci-hcd.c +++ b/drivers/usb/host/ehci-hcd.c | |||
@@ -42,6 +42,9 @@ | |||
42 | #include <asm/irq.h> | 42 | #include <asm/irq.h> |
43 | #include <asm/system.h> | 43 | #include <asm/system.h> |
44 | #include <asm/unaligned.h> | 44 | #include <asm/unaligned.h> |
45 | #ifdef CONFIG_PPC_PS3 | ||
46 | #include <asm/firmware.h> | ||
47 | #endif | ||
45 | 48 | ||
46 | 49 | ||
47 | /*-------------------------------------------------------------------------*/ | 50 | /*-------------------------------------------------------------------------*/ |
@@ -968,15 +971,18 @@ static int __init ehci_hcd_init(void) | |||
968 | #endif | 971 | #endif |
969 | 972 | ||
970 | #ifdef PS3_SYSTEM_BUS_DRIVER | 973 | #ifdef PS3_SYSTEM_BUS_DRIVER |
971 | retval = ps3_system_bus_driver_register(&PS3_SYSTEM_BUS_DRIVER); | 974 | if (firmware_has_feature(FW_FEATURE_PS3_LV1)) { |
972 | if (retval < 0) { | 975 | retval = ps3_system_bus_driver_register( |
976 | &PS3_SYSTEM_BUS_DRIVER); | ||
977 | if (retval < 0) { | ||
973 | #ifdef PLATFORM_DRIVER | 978 | #ifdef PLATFORM_DRIVER |
974 | platform_driver_unregister(&PLATFORM_DRIVER); | 979 | platform_driver_unregister(&PLATFORM_DRIVER); |
975 | #endif | 980 | #endif |
976 | #ifdef PCI_DRIVER | 981 | #ifdef PCI_DRIVER |
977 | pci_unregister_driver(&PCI_DRIVER); | 982 | pci_unregister_driver(&PCI_DRIVER); |
978 | #endif | 983 | #endif |
979 | return retval; | 984 | return retval; |
985 | } | ||
980 | } | 986 | } |
981 | #endif | 987 | #endif |
982 | 988 | ||
@@ -993,7 +999,8 @@ static void __exit ehci_hcd_cleanup(void) | |||
993 | pci_unregister_driver(&PCI_DRIVER); | 999 | pci_unregister_driver(&PCI_DRIVER); |
994 | #endif | 1000 | #endif |
995 | #ifdef PS3_SYSTEM_BUS_DRIVER | 1001 | #ifdef PS3_SYSTEM_BUS_DRIVER |
996 | ps3_system_bus_driver_unregister(&PS3_SYSTEM_BUS_DRIVER); | 1002 | if (firmware_has_feature(FW_FEATURE_PS3_LV1)) |
1003 | ps3_system_bus_driver_unregister(&PS3_SYSTEM_BUS_DRIVER); | ||
997 | #endif | 1004 | #endif |
998 | } | 1005 | } |
999 | module_exit(ehci_hcd_cleanup); | 1006 | module_exit(ehci_hcd_cleanup); |