X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fusb%2Fhost%2Fehci-hcd.c;fp=drivers%2Fusb%2Fhost%2Fehci-hcd.c;h=9dd3d14c64f3cd6c04a4cb908b9a0ae618c81f86;hb=64ba3f394c830ec48a1c31b53dcae312c56f1604;hp=d63177a8eaea330b41e6465f740efa4d7b3ba3c7;hpb=be1e6109ac94a859551f8e1774eb9a8469fe055c;p=linux-2.6.git diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c index d63177a8e..9dd3d14c6 100644 --- a/drivers/usb/host/ehci-hcd.c +++ b/drivers/usb/host/ehci-hcd.c @@ -16,6 +16,7 @@ * Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#include #include #include #include @@ -625,11 +626,10 @@ static irqreturn_t ehci_irq (struct usb_hcd *hcd, struct pt_regs *regs) writel (status | CMD_RUN, &ehci->regs->command); while (i--) { - int pstatus = readl (&ehci->regs->port_status [i]); - - if (pstatus & PORT_OWNER) + status = readl (&ehci->regs->port_status [i]); + if (status & PORT_OWNER) continue; - if (!(pstatus & PORT_RESUME) + if (!(status & PORT_RESUME) || ehci->reset_done [i] != 0) continue; @@ -889,59 +889,8 @@ MODULE_LICENSE ("GPL"); #ifdef CONFIG_PCI #include "ehci-pci.c" -#define PCI_DRIVER ehci_pci_driver -#endif - -#ifdef CONFIG_MPC834x -#include "ehci-fsl.c" -#define PLATFORM_DRIVER ehci_fsl_driver #endif -#ifdef CONFIG_SOC_AU1200 -#include "ehci-au1xxx.c" -#define PLATFORM_DRIVER ehci_hcd_au1xxx_driver -#endif - -#if !defined(PCI_DRIVER) && !defined(PLATFORM_DRIVER) +#if !defined(CONFIG_PCI) #error "missing bus glue for ehci-hcd" #endif - -static int __init ehci_hcd_init(void) -{ - int retval = 0; - - pr_debug("%s: block sizes: qh %Zd qtd %Zd itd %Zd sitd %Zd\n", - hcd_name, - sizeof(struct ehci_qh), sizeof(struct ehci_qtd), - sizeof(struct ehci_itd), sizeof(struct ehci_sitd)); - -#ifdef PLATFORM_DRIVER - retval = platform_driver_register(&PLATFORM_DRIVER); - if (retval < 0) - return retval; -#endif - -#ifdef PCI_DRIVER - retval = pci_register_driver(&PCI_DRIVER); - if (retval < 0) { -#ifdef PLATFORM_DRIVER - platform_driver_unregister(&PLATFORM_DRIVER); -#endif - } -#endif - - return retval; -} -module_init(ehci_hcd_init); - -static void __exit ehci_hcd_cleanup(void) -{ -#ifdef PLATFORM_DRIVER - platform_driver_unregister(&PLATFORM_DRIVER); -#endif -#ifdef PCI_DRIVER - pci_unregister_driver(&PCI_DRIVER); -#endif -} -module_exit(ehci_hcd_cleanup); -