MLK-16013-32 usb: typec: refine source to sink swap handling
authorLi Jun <jun.li@nxp.com>
Wed, 9 Jan 2019 07:09:10 +0000 (12:39 +0530)
committerLeonard Crestez <leonard.crestez@nxp.com>
Wed, 17 Apr 2019 23:51:34 +0000 (02:51 +0300)
commit75d2109382bb56285f63974f6dec7bbc2d388525
tree7804345924fe28a24fff5d8720d279cee52fda68
parent5ab85a9540b925746e987af702e7f991ffeaf4ae
MLK-16013-32 usb: typec: refine source to sink swap handling

To early start sink power after source turn off vbus, move the set power
role after vbus is turned off in PR_SWAP_SRC_SNK_SOURCE_OFF, also per
spec, we should do error recovery if the sink side does not turn on
vbus in PD_T_PS_SOURCE_ON.

Reviewed-by: Peter Chen <peter.chen@nxp.com>
Signed-off-by: Li Jun <jun.li@nxp.com>
Signed-off-by: Vipul Kumar <vipul_kumar@mentor.com>
drivers/usb/typec/tcpm.c