diff options
author | Gil Fine <gil.fine@intel.com> | 2022-09-29 13:17:24 +0300 |
---|---|---|
committer | Mika Westerberg <mika.westerberg@linux.intel.com> | 2023-06-16 09:53:28 +0300 |
commit | 14200a2631dd1f041201985e2a757d2d06ba2524 (patch) | |
tree | 925c2bf866e230350a363659049f897c70f53342 /drivers/thunderbolt/switch.c | |
parent | 0fc70886569c8459c4494ba9ef8c4ef34b81e781 (diff) | |
download | linux-stable-14200a2631dd1f041201985e2a757d2d06ba2524.tar.gz linux-stable-14200a2631dd1f041201985e2a757d2d06ba2524.tar.bz2 linux-stable-14200a2631dd1f041201985e2a757d2d06ba2524.zip |
thunderbolt: Announce USB4 v2 connection manager support
Program the CMUV (Connection Manager USB4 Version) field for USB4 v2 and
v1 routers according to the spec.
Signed-off-by: Gil Fine <gil.fine@intel.com>
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Diffstat (limited to 'drivers/thunderbolt/switch.c')
-rw-r--r-- | drivers/thunderbolt/switch.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/thunderbolt/switch.c b/drivers/thunderbolt/switch.c index a0451218af2a..ebe9559c8c79 100644 --- a/drivers/thunderbolt/switch.c +++ b/drivers/thunderbolt/switch.c @@ -2430,9 +2430,13 @@ int tb_switch_configure(struct tb_switch *sw) /* * For USB4 devices, we need to program the CM version * accordingly so that it knows to expose all the - * additional capabilities. + * additional capabilities. Program it according to USB4 + * version to avoid changing existing (v1) routers behaviour. */ - sw->config.cmuv = USB4_VERSION_1_0; + if (usb4_switch_version(sw) < 2) + sw->config.cmuv = ROUTER_CS_4_CMUV_V1; + else + sw->config.cmuv = ROUTER_CS_4_CMUV_V2; sw->config.plug_events_delay = 0xa; /* Enumerate the switch */ |