MLK-16013-23 usb: typec: tcpm: Do soft reset for unexpected get sink cap
authorLi Jun <jun.li@nxp.com>
Wed, 9 Jan 2019 06:14:38 +0000 (11:44 +0530)
committerLeonard Crestez <leonard.crestez@nxp.com>
Wed, 17 Apr 2019 23:51:34 +0000 (02:51 +0300)
commitac7f74d32ba8ddf0f8b90d5869307c9799b17ba2
treeb36c43961f440dbdcc4497b7c1d9aecf8675c1e8
parent6e1a5fe2587fb9c01bd30e7a6d9763af846dddd3
MLK-16013-23 usb: typec: tcpm: Do soft reset for unexpected get sink cap

A source or sink should receive the get_sink_cap message when in SRC_RDY or
SNK_RDY, if the port receives a get sink capability request before ready,
which means there is message sync error, we should do soft reset to recover
from it, instead of sending a reject message.

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