diff options
Diffstat (limited to 'drivers/usb/host/ehci-mxc.c')
-rw-r--r-- | drivers/usb/host/ehci-mxc.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/drivers/usb/host/ehci-mxc.c b/drivers/usb/host/ehci-mxc.c index ac9c4d7c44af..bce85055019a 100644 --- a/drivers/usb/host/ehci-mxc.c +++ b/drivers/usb/host/ehci-mxc.c | |||
@@ -36,6 +36,8 @@ struct ehci_mxc_priv { | |||
36 | static int ehci_mxc_setup(struct usb_hcd *hcd) | 36 | static int ehci_mxc_setup(struct usb_hcd *hcd) |
37 | { | 37 | { |
38 | struct ehci_hcd *ehci = hcd_to_ehci(hcd); | 38 | struct ehci_hcd *ehci = hcd_to_ehci(hcd); |
39 | struct device *dev = hcd->self.controller; | ||
40 | struct mxc_usbh_platform_data *pdata = dev_get_platdata(dev); | ||
39 | int retval; | 41 | int retval; |
40 | 42 | ||
41 | /* EHCI registers start at offset 0x100 */ | 43 | /* EHCI registers start at offset 0x100 */ |
@@ -63,6 +65,12 @@ static int ehci_mxc_setup(struct usb_hcd *hcd) | |||
63 | 65 | ||
64 | ehci_reset(ehci); | 66 | ehci_reset(ehci); |
65 | 67 | ||
68 | /* set up the PORTSCx register */ | ||
69 | ehci_writel(ehci, pdata->portsc, &ehci->regs->port_status[0]); | ||
70 | |||
71 | /* is this really needed? */ | ||
72 | msleep(10); | ||
73 | |||
66 | ehci_port_power(ehci, 0); | 74 | ehci_port_power(ehci, 0); |
67 | return 0; | 75 | return 0; |
68 | } | 76 | } |
@@ -114,7 +122,7 @@ static int ehci_mxc_drv_probe(struct platform_device *pdev) | |||
114 | struct mxc_usbh_platform_data *pdata = pdev->dev.platform_data; | 122 | struct mxc_usbh_platform_data *pdata = pdev->dev.platform_data; |
115 | struct usb_hcd *hcd; | 123 | struct usb_hcd *hcd; |
116 | struct resource *res; | 124 | struct resource *res; |
117 | int irq, ret, temp; | 125 | int irq, ret; |
118 | struct ehci_mxc_priv *priv; | 126 | struct ehci_mxc_priv *priv; |
119 | struct device *dev = &pdev->dev; | 127 | struct device *dev = &pdev->dev; |
120 | 128 | ||
@@ -188,10 +196,6 @@ static int ehci_mxc_drv_probe(struct platform_device *pdev) | |||
188 | clk_enable(priv->ahbclk); | 196 | clk_enable(priv->ahbclk); |
189 | } | 197 | } |
190 | 198 | ||
191 | /* set up the PORTSCx register */ | ||
192 | ehci_writel(ehci, pdata->portsc, &ehci->regs->port_status[0]); | ||
193 | mdelay(10); | ||
194 | |||
195 | /* setup specific usb hw */ | 199 | /* setup specific usb hw */ |
196 | ret = mxc_initialize_usb_hw(pdev->id, pdata->flags); | 200 | ret = mxc_initialize_usb_hw(pdev->id, pdata->flags); |
197 | if (ret < 0) | 201 | if (ret < 0) |