diff options
| -rw-r--r-- | drivers/usb/host/ehci-mxc.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/drivers/usb/host/ehci-mxc.c b/drivers/usb/host/ehci-mxc.c index 544ccfd7056e..bd4027745aa7 100644 --- a/drivers/usb/host/ehci-mxc.c +++ b/drivers/usb/host/ehci-mxc.c | |||
| @@ -207,10 +207,17 @@ static int ehci_mxc_drv_probe(struct platform_device *pdev) | |||
| 207 | /* Initialize the transceiver */ | 207 | /* Initialize the transceiver */ |
| 208 | if (pdata->otg) { | 208 | if (pdata->otg) { |
| 209 | pdata->otg->io_priv = hcd->regs + ULPI_VIEWPORT_OFFSET; | 209 | pdata->otg->io_priv = hcd->regs + ULPI_VIEWPORT_OFFSET; |
| 210 | if (otg_init(pdata->otg) != 0) | 210 | ret = otg_init(pdata->otg); |
| 211 | dev_err(dev, "unable to init transceiver\n"); | 211 | if (ret) { |
| 212 | else if (otg_set_vbus(pdata->otg, 1) != 0) | 212 | dev_err(dev, "unable to init transceiver, probably missing\n"); |
| 213 | ret = -ENODEV; | ||
| 214 | goto err_add; | ||
| 215 | } | ||
| 216 | ret = otg_set_vbus(pdata->otg, 1); | ||
| 217 | if (ret) { | ||
| 213 | dev_err(dev, "unable to enable vbus on transceiver\n"); | 218 | dev_err(dev, "unable to enable vbus on transceiver\n"); |
| 219 | goto err_add; | ||
| 220 | } | ||
| 214 | } | 221 | } |
| 215 | 222 | ||
| 216 | priv->hcd = hcd; | 223 | priv->hcd = hcd; |
