Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 687f3f93 authored by Chandana Kishori Chiluveru's avatar Chandana Kishori Chiluveru Committed by Jack Pham
Browse files

usb: pd: Add timeout for mode change



Currently USB driver tries to set power role as none in mode
change and waits for disconnect followed by connect notifications
to set new mode. But there is a chance that it might fail if other
device is not dual-role capable.

When device connected to window host pc and try data role swap.
Device trying to change the mode and setting the power role none.
But host PC does not support this and device never switching back
to original role and device enumeration does not happening with
host pc connected.

Fix it by having timeouts in mode setting. Setting it to dual-role and
bail out in case of timeout happens.

Change-Id: Iaac671f46070f756243b93a27ab99ddbbdff8ffa
Signed-off-by: default avatarChandana Kishori Chiluveru <cchiluve@codeaurora.org>
Signed-off-by: default avatarJack Pham <jackp@codeaurora.org>
parent f2ba4b52
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment