aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ehci-ixp4xx.c
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2012-07-09 15:55:14 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-07-09 16:35:05 -0400
commit1a49e2ac9651df7349867a5cf44e2c83de1046af (patch)
treeb4ba01d645073947dcf8bbe1972b7af740031b5b /drivers/usb/host/ehci-ixp4xx.c
parent1530280084c3905be6fce802cbfa83fb3bbb8839 (diff)
EHCI: centralize controller initialization
This patch (as1564c) converts the EHCI platform drivers to use the central ehci_setup() routine for generic controller initialization rather than each having its own idiosyncratic approach. The major point of difficulty lies in ehci-pci's many vendor- and device-specific workarounds. Some of them have to be applied before calling ehci_setup() and some after, which necessitates a fair amount of code motion. The other platform drivers require much smaller changes. One point not addressed by the patch is whether ports should be powered on or off following initialization. The different drivers appear to handle this pretty much at random. In fact it shouldn't matter, because the hub driver turns on power to all ports when it binds to the root hub. Straightening that out will be left for another day. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/host/ehci-ixp4xx.c')
-rw-r--r--drivers/usb/host/ehci-ixp4xx.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/usb/host/ehci-ixp4xx.c b/drivers/usb/host/ehci-ixp4xx.c
index c4460f3d009f..488d401942e9 100644
--- a/drivers/usb/host/ehci-ixp4xx.c
+++ b/drivers/usb/host/ehci-ixp4xx.c
@@ -22,14 +22,10 @@ static int ixp4xx_ehci_init(struct usb_hcd *hcd)
22 ehci->big_endian_mmio = 1; 22 ehci->big_endian_mmio = 1;
23 23
24 ehci->caps = hcd->regs + 0x100; 24 ehci->caps = hcd->regs + 0x100;
25 ehci->regs = hcd->regs + 0x100
26 + HC_LENGTH(ehci, ehci_readl(ehci, &ehci->caps->hc_capbase));
27 ehci->hcs_params = ehci_readl(ehci, &ehci->caps->hcs_params);
28 25
29 hcd->has_tt = 1; 26 hcd->has_tt = 1;
30 ehci_reset(ehci);
31 27
32 retval = ehci_init(hcd); 28 retval = ehci_setup(hcd);
33 if (retval) 29 if (retval)
34 return retval; 30 return retval;
35 31