diff options
author | Ayushee <ayushee.shah@intel.com> | 2020-10-16 14:02:22 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-10-21 00:35:48 +0000 |
commit | ef23cf615a0dcc853d373c6fc766c60032e9f9b3 (patch) | |
tree | ebb62473d994f6f5034965f4c7d9d6ea2ff5c047 /common/usb_pd_alt_mode_dfp.c | |
parent | d6458e209c36770ec482a25e5d2e8e29cb20dcac (diff) | |
download | chrome-ec-ef23cf615a0dcc853d373c6fc766c60032e9f9b3.tar.gz |
TCPMv2: Correct Enter Mode TBT payload
According to Type-C ENGINEERING CHANGE NOTICE (ECN) "USB Type-C ECN
Thunderbolt 3 Compatibility Updates for the document fix published
by USB-IF,
For Enter mode Thunderbolt payload,
B25 - Active_Passive bit
B24 - Thunderbolt Adapter
This CL corrects setting B24 and B25 and sets lrx_comm(23),
retimer_type(22), tbt_cable(21) irrespective of the cable speed.
BUG=b:148534741
BRANCH=None
TEST=Able to enter into Thunderbolt mode with Active and Passie cable
Signed-off-by: Ayushee <ayushee.shah@intel.com>
Change-Id: I7fb29bea972f23ee0f87ee27ddcc1a50ce2d9a69
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2481933
Reviewed-by: Vijay P Hiremath <vijay.p.hiremath@intel.com>
Reviewed-by: Abe Levkoy <alevkoy@chromium.org>
Diffstat (limited to 'common/usb_pd_alt_mode_dfp.c')
-rw-r--r-- | common/usb_pd_alt_mode_dfp.c | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/common/usb_pd_alt_mode_dfp.c b/common/usb_pd_alt_mode_dfp.c index aba8075a27..ad193a35e1 100644 --- a/common/usb_pd_alt_mode_dfp.c +++ b/common/usb_pd_alt_mode_dfp.c @@ -847,21 +847,11 @@ int enter_tbt_compat_mode(int port, enum tcpm_transmit_type sop, enter_dev_mode.cable = get_usb_pd_cable_type(port) == IDH_PTYPE_PCABLE ? TBT_ENTER_PASSIVE_CABLE : TBT_ENTER_ACTIVE_CABLE; - - if (get_tbt_cable_speed(port) == TBT_SS_TBT_GEN3) { - enter_dev_mode.lsrx_comm = - cable_mode_resp.lsrx_comm; - enter_dev_mode.retimer_type = - cable_mode_resp.retimer_type; - enter_dev_mode.tbt_cable = - cable_mode_resp.tbt_cable; - enter_dev_mode.tbt_rounded = - cable_mode_resp.tbt_rounded; - enter_dev_mode.tbt_cable_speed = - cable_mode_resp.tbt_cable_speed; - } else { - enter_dev_mode.tbt_cable_speed = TBT_SS_U32_GEN1_GEN2; - } + enter_dev_mode.lsrx_comm = cable_mode_resp.lsrx_comm; + enter_dev_mode.retimer_type = cable_mode_resp.retimer_type; + enter_dev_mode.tbt_cable = cable_mode_resp.tbt_cable; + enter_dev_mode.tbt_rounded = cable_mode_resp.tbt_rounded; + enter_dev_mode.tbt_cable_speed = get_tbt_cable_speed(port); enter_dev_mode.tbt_alt_mode = TBT_ALTERNATE_MODE; payload[1] = enter_dev_mode.raw_value; |