[PATCH 5/5] usb: musb: dsps: run the timer only on OTG systems

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I introduced this check here because it looked wrong in HOST only
configurions. The timer would remove that session bit and will never
come back and so there would not be another session.
Now that I played with OTG for a while I belive this workaround is
only required for the OTG mode because we have to end the session and
then we have to try to start manually.
Therefore, this patch limits this timer to the OTG only port mode so we
don't need to poll around in device only mode.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@xxxxxxxxxxxxx>
---
 drivers/usb/musb/musb_dsps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/usb/musb/musb_dsps.c b/drivers/usb/musb/musb_dsps.c
index e3dce9b..c5010ef 100644
--- a/drivers/usb/musb/musb_dsps.c
+++ b/drivers/usb/musb/musb_dsps.c
@@ -138,7 +138,7 @@ static void dsps_musb_try_idle(struct musb *musb, unsigned long timeout)
 		glue->last_timer = jiffies;
 		return;
 	}
-	if (musb->port_mode == MUSB_PORT_MODE_HOST)
+	if (musb->port_mode != MUSB_PORT_MODE_DUAL_ROLE)
 		return;
 
 	if (!musb->g.dev.driver)
-- 
1.8.4.rc3

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux