Commit b8239dcc authored by Bin Liu's avatar Bin Liu Committed by Felipe Balbi

usb: musb: dsps: fix polling in device-only mode

Fix the regression caused by commit ad78c918 ("usb: musb: dsps: just
start polling already") which causes polling the ID pin status even in
device-only mode.

Fixes: ad78c918 ("usb: musb: dsps: just start polling already")
Signed-off-by: default avatarBin Liu <b-liu@ti.com>
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent cf261fd1
......@@ -225,8 +225,11 @@ static void dsps_musb_enable(struct musb *musb)
dsps_writel(reg_base, wrp->epintr_set, epmask);
dsps_writel(reg_base, wrp->coreintr_set, coremask);
/* start polling for ID change. */
mod_timer(&glue->timer, jiffies + msecs_to_jiffies(wrp->poll_timeout));
/* start polling for ID change in dual-role idle mode */
if (musb->xceiv->otg->state == OTG_STATE_B_IDLE &&
musb->port_mode == MUSB_PORT_MODE_DUAL_ROLE)
mod_timer(&glue->timer, jiffies +
msecs_to_jiffies(wrp->poll_timeout));
dsps_musb_try_idle(musb, 0);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment