diff options
author | Abe Levkoy <alevkoy@chromium.org> | 2021-02-04 12:17:20 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-02-08 20:59:20 +0000 |
commit | 2782311fcd09830fef85734708f5d24b64cd176d (patch) | |
tree | 9165ac13e99d2be1036aac898a40719b58f483f0 /include/usb_prl_sm.h | |
parent | d8b6fbf8acddc7fba611e8cf11732e42d8bcc257 (diff) | |
download | chrome-ec-2782311fcd09830fef85734708f5d24b64cd176d.tar.gz |
TCPMv2: Reset stored PD revs at appropriate times
Stored PD revs for partners should only be reset upon Detach, Hard
Reset, or Error Recovery. Don't do it when the PE enters a Startup
state, e.g. after a Power Role Swap.
BUG=b:173725284,b:179198412
TEST=make buildall
TEST=PR Swap after SOP' Discover Identity with PD 2.0 cable; subsequent
SOP' messages still PD 2.0; subsequent Enter_USB message has
correct cable speed
BRANCH=none
Signed-off-by: Abe Levkoy <alevkoy@chromium.org>
Change-Id: I2c12287c99154fba96e4f04a76ebc48273b0bb2e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2676265
Reviewed-by: Diana Z <dzigterman@chromium.org>
Tested-by: Divya Sasidharan <divya.s.sasidharan@intel.corp-partner.google.com>
Tested-by: Ayushee Shah <ayushee.shah@intel.com>
Diffstat (limited to 'include/usb_prl_sm.h')
-rw-r--r-- | include/usb_prl_sm.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/include/usb_prl_sm.h b/include/usb_prl_sm.h index 6a143f9acc..79b0b9c35c 100644 --- a/include/usb_prl_sm.h +++ b/include/usb_prl_sm.h @@ -45,13 +45,24 @@ void prl_set_debug_level(enum debug_level level); void prl_reset(int port); /** - * Resets the Protocol Layer State Machine (softly) + * Resets the Protocol Layer state machine but does not reset the stored PD + * revisions of the partners. * * @param port USB-C port number */ void prl_reset_soft(int port); /** + * resets the stored pd revisions for each sop type to their default value, the + * highest revision supported by this implementation. per pd r3.0 v2.0, + * ss6.2.1.1.5, this should only happen upon detach, hard reset, or error + * recovery. + * + * @param port USB-C port number + */ +void prl_set_default_pd_revision(int port); + +/** * Runs the Protocol Layer State Machine * * @param port USB-C port number |