Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 364351
b: refs/heads/master
c: 49f0921
h: refs/heads/master
i:
  364349: 7301126
  364347: ca3fef3
  364343: ce824d8
  364335: 86c871f
  364319: b1d4079
  364287: 034af96
v: v3
  • Loading branch information
Roger Quadros authored and Greg Kroah-Hartman committed Mar 15, 2013
1 parent 82550ff commit 00ffcd7
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 18 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a2f450ca88a394e282f09e5e16f9de60cd487f80
refs/heads/master: 49f092198f4fd2c70847de7151d33df08929af51
32 changes: 15 additions & 17 deletions trunk/drivers/usb/host/ehci-omap.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,26 +90,13 @@ static inline u32 ehci_read(void __iomem *base, u32 reg)
static int omap_ehci_init(struct usb_hcd *hcd)
{
struct ehci_hcd *ehci = hcd_to_ehci(hcd);
struct omap_hcd *omap = (struct omap_hcd *)ehci->priv;
int rc, i;

/* Hold PHYs in reset while initializing EHCI controller */
for (i = 0; i < omap->nports; i++) {
if (omap->phy[i])
usb_phy_shutdown(omap->phy[i]);
}
int rc;

/* we know this is the memory we want, no need to ioremap again */
ehci->caps = hcd->regs;

rc = ehci_setup(hcd);

/* Bring PHYs out of reset */
for (i = 0; i < omap->nports; i++) {
if (omap->phy[i])
usb_phy_init(omap->phy[i]);
}

return rc;
}

Expand Down Expand Up @@ -219,9 +206,6 @@ static int ehci_hcd_omap_probe(struct platform_device *pdev)
}

omap->phy[i] = phy;
usb_phy_init(omap->phy[i]);
/* bring PHY out of suspend */
usb_phy_set_suspend(omap->phy[i], 0);
}

pm_runtime_enable(dev);
Expand All @@ -245,6 +229,20 @@ static int ehci_hcd_omap_probe(struct platform_device *pdev)
goto err_pm_runtime;
}

/*
* Bring PHYs out of reset.
* Even though HSIC mode is a PHY-less mode, the reset
* line exists between the chips and can be modelled
* as a PHY device for reset control.
*/
for (i = 0; i < omap->nports; i++) {
if (!omap->phy[i])
continue;

usb_phy_init(omap->phy[i]);
/* bring PHY out of suspend */
usb_phy_set_suspend(omap->phy[i], 0);
}

return 0;

Expand Down

0 comments on commit 00ffcd7

Please sign in to comment.