aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ehci-hcd.c
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2012-11-01 11:13:04 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-11-01 11:51:12 -0400
commitadfa79d1c06a32650332930ca4c488ca570b3407 (patch)
treea7dfd00bdec32dbfbd52d018e5daf3a1bb2d0808 /drivers/usb/host/ehci-hcd.c
parent3e0232039967d7a1a06c013d097458b4d5892af1 (diff)
USB: EHCI: make ehci-pci a separate driver
This patch (as1625) splits the PCI portion of ehci-hcd out into its own separate driver module, called ehci-pci. Consistently with the current practice, the decision whether to build this module is not user-configurable. If EHCI and PCI are enabled then the module will be built, always. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> CC: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/host/ehci-hcd.c')
-rw-r--r--drivers/usb/host/ehci-hcd.c26
1 files changed, 5 insertions, 21 deletions
diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c
index dee3541bfae8..7113d6ad24f7 100644
--- a/drivers/usb/host/ehci-hcd.c
+++ b/drivers/usb/host/ehci-hcd.c
@@ -1252,11 +1252,6 @@ MODULE_DESCRIPTION(DRIVER_DESC);
1252MODULE_AUTHOR (DRIVER_AUTHOR); 1252MODULE_AUTHOR (DRIVER_AUTHOR);
1253MODULE_LICENSE ("GPL"); 1253MODULE_LICENSE ("GPL");
1254 1254
1255#ifdef CONFIG_PCI
1256#include "ehci-pci.c"
1257#define PCI_DRIVER ehci_pci_driver
1258#endif
1259
1260#ifdef CONFIG_USB_EHCI_FSL 1255#ifdef CONFIG_USB_EHCI_FSL
1261#include "ehci-fsl.c" 1256#include "ehci-fsl.c"
1262#define PLATFORM_DRIVER ehci_fsl_driver 1257#define PLATFORM_DRIVER ehci_fsl_driver
@@ -1367,9 +1362,11 @@ MODULE_LICENSE ("GPL");
1367#define PLATFORM_DRIVER ehci_platform_driver 1362#define PLATFORM_DRIVER ehci_platform_driver
1368#endif 1363#endif
1369 1364
1370#if !defined(PCI_DRIVER) && !defined(PLATFORM_DRIVER) && \ 1365#if !IS_ENABLED(CONFIG_USB_EHCI_PCI) && \
1371 !defined(PS3_SYSTEM_BUS_DRIVER) && !defined(OF_PLATFORM_DRIVER) && \ 1366 !defined(PLATFORM_DRIVER) && \
1372 !defined(XILINX_OF_PLATFORM_DRIVER) 1367 !defined(PS3_SYSTEM_BUS_DRIVER) && \
1368 !defined(OF_PLATFORM_DRIVER) && \
1369 !defined(XILINX_OF_PLATFORM_DRIVER)
1373#error "missing bus glue for ehci-hcd" 1370#error "missing bus glue for ehci-hcd"
1374#endif 1371#endif
1375 1372
@@ -1406,12 +1403,6 @@ static int __init ehci_hcd_init(void)
1406 goto clean0; 1403 goto clean0;
1407#endif 1404#endif
1408 1405
1409#ifdef PCI_DRIVER
1410 retval = pci_register_driver(&PCI_DRIVER);
1411 if (retval < 0)
1412 goto clean1;
1413#endif
1414
1415#ifdef PS3_SYSTEM_BUS_DRIVER 1406#ifdef PS3_SYSTEM_BUS_DRIVER
1416 retval = ps3_ehci_driver_register(&PS3_SYSTEM_BUS_DRIVER); 1407 retval = ps3_ehci_driver_register(&PS3_SYSTEM_BUS_DRIVER);
1417 if (retval < 0) 1408 if (retval < 0)
@@ -1443,10 +1434,6 @@ clean3:
1443 ps3_ehci_driver_unregister(&PS3_SYSTEM_BUS_DRIVER); 1434 ps3_ehci_driver_unregister(&PS3_SYSTEM_BUS_DRIVER);
1444clean2: 1435clean2:
1445#endif 1436#endif
1446#ifdef PCI_DRIVER
1447 pci_unregister_driver(&PCI_DRIVER);
1448clean1:
1449#endif
1450#ifdef PLATFORM_DRIVER 1437#ifdef PLATFORM_DRIVER
1451 platform_driver_unregister(&PLATFORM_DRIVER); 1438 platform_driver_unregister(&PLATFORM_DRIVER);
1452clean0: 1439clean0:
@@ -1472,9 +1459,6 @@ static void __exit ehci_hcd_cleanup(void)
1472#ifdef PLATFORM_DRIVER 1459#ifdef PLATFORM_DRIVER
1473 platform_driver_unregister(&PLATFORM_DRIVER); 1460 platform_driver_unregister(&PLATFORM_DRIVER);
1474#endif 1461#endif
1475#ifdef PCI_DRIVER
1476 pci_unregister_driver(&PCI_DRIVER);
1477#endif
1478#ifdef PS3_SYSTEM_BUS_DRIVER 1462#ifdef PS3_SYSTEM_BUS_DRIVER
1479 ps3_ehci_driver_unregister(&PS3_SYSTEM_BUS_DRIVER); 1463 ps3_ehci_driver_unregister(&PS3_SYSTEM_BUS_DRIVER);
1480#endif 1464#endif