[PATCH 2/2] platform/chrome: cros_ec_typec: Send mux configuration acknowledgment to EC

2020-12-09 Thread Utkarsh Patel
. This change also brings in corresponding EC header updates from the EC code base [1]. [1]: https://chromium.googlesource.com/chromiumos/platform/ec/+/refs/heads/master/include/ec_commands.h Signed-off-by: Utkarsh Patel --- drivers/platform/chrome/cros_ec_typec.c| 16

[PATCH 0/2] Send acknowledgment to ec from cors_ec_typec

2020-12-09 Thread Utkarsh Patel
This adds mechanism of sending mux configuration acknowledgment from kernel to EC. It also modifies cros_typec_cmds_supported() to support multiple feature flags. Utkarsh Patel (2): platform/chrome: cros_ec_typec: Parameterize cros_typec_cmds_supported() platform/chrome: cros_ec_typec

[PATCH 1/2] platform/chrome: cros_ec_typec: Parameterize cros_typec_cmds_supported()

2020-12-09 Thread Utkarsh Patel
cros_typec_cmds_supported() is currently being used to check only one feature flag. Add a new feature parameter to it so that it can be used to check multiple feature flags supported in cros_ec. Rename cros_typec_cmds_supported() to cros_typec_feature_supported(). Signed-off-by: Utkarsh Patel

[PATCH v4 1/1] usb: typec: intel_pmc_mux: Configure cable generation value for USB4

2020-12-08 Thread Utkarsh Patel
USB4 specification chapter 3 indicates that cable data rates have to be rounded for USB4 device to operate as USB4. With that configure cable generation value to use rounded data rates for USB4. Signed-off-by: Utkarsh Patel --- Changes in v4: - Removed usage of tbt_mode_vdo since data rates

[PATCH v4 0/1] Thunderbolt3/USB4 cable rounded and active cable plug link training support

2020-12-08 Thread Utkarsh Patel
1/8, 2/8 and 4/8. Utkarsh Patel (1): usb: typec: intel_pmc_mux: Configure cable generation value for USB4 drivers/usb/typec/mux/intel_pmc_mux.c | 5 + 1 file changed, 5 insertions(+) -- 2.17.1

[PATCH] usb: typec: intel_pmc_mux: Use correct response message bits

2020-12-03 Thread Utkarsh Patel
Signed-off-by: Utkarsh Patel --- drivers/usb/typec/mux/intel_pmc_mux.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/usb/typec/mux/intel_pmc_mux.c b/drivers/usb/typec/mux/intel_pmc_mux.c index aa3211f1c4c3..e58ae8a7fefb 100644 --- a/drivers/usb/t

[PATCH v3 1/4] usb: typec: Use Thunderbolt 3 cable discover mode VDO in Enter_USB message

2020-11-18 Thread Utkarsh Patel
When Thunderbolt 3 cable is being used to create USB4 connection, use Thunderbolt 3 discover mode VDO to fill details such as active cable plug link training and cable rounded support. With USB4 cables, these VDO members need not be filled. Suggested-by: Heikki Krogerus Signed-off-by: Utkarsh

[PATCH v3 3/4] usb: typec: intel_pmc_mux: Configure active cable properties for USB4

2020-11-18 Thread Utkarsh Patel
Value received as a part of Thunderbolt 3 cable discover mode VDO needs to be configured in the USB4 mode for the cable rounded support and active cable plug link training. Suggested-by: Heikki Krogerus Signed-off-by: Utkarsh Patel -- Changes in v3: - Moved TBT_CABLE_ROUNDED_SUPPORT assignment

[PATCH v3 4/4] usb: typec: Remove active_link_training variable from Enter_USB message

2020-11-18 Thread Utkarsh Patel
Thunderbolt 3 cable discover mode VDO support has been added as part of Enter_USB message to fill details of active cable plug link training. Hence, removing unused variable active_link_training from Enter_USB message data structure. Signed-off-by: Utkarsh Patel Reviewed-by: Heikki Krogerus

[PATCH v3 2/4] platform/chrome: cros_ec_typec: Use Thunderbolt 3 cable discover mode VDO in USB4 mode

2020-11-18 Thread Utkarsh Patel
Configure Thunderbolt 3 cable generation value by filling Thunderbolt 3 cable discover mode VDO to support rounded Thunderbolt 3 cables. While we are here use Thunderbolt 3 cable discover mode VDO to fill active cable plug link training value. Suggested-by: Heikki Krogerus Signed-off-by: Utkarsh

[PATCH v3 0/4] Thunderbolt3/USB4 cable rounded and active cable plug link training support

2020-11-18 Thread Utkarsh Patel
as there is no functional implication from patches 1/8, 2/8 and 4/8. Utkarsh Patel (4): usb: typec: Use Thunderbolt 3 cable discover mode VDO in Enter_USB message platform/chrome: cros_ec_typec: Use Thunderbolt 3 cable discover mode VDO in USB4 mode usb: typec: intel_pmc_mux

[PATCH v2 0/8] Thunderbolt3/USB4 cable rounded and active cable plug link training support

2020-11-13 Thread Utkarsh Patel
This patch series adds the support for Thunderbolt3/USB4 rounded and non-rounded frequencies cables and fixes the active cable plug link training support. Changes in v2: - Removed the fixes tag as there is no functional implication from patches 1/8, 2/8 and 4/8. Utkarsh Patel (8): usb: typec

[PATCH v2 5/8] usb: typec: Use Thunderbolt 3 cable discover mode VDO in Enter_USB message

2020-11-13 Thread Utkarsh Patel
USB4 also uses same cable properties as Thunderbolt 3 so use Thunderbolt 3 cable discover mode VDO to fill details such as active cable plug link training and cable rounded support. Suggested-by: Heikki Krogerus Signed-off-by: Utkarsh Patel -- Changes in v2: - No change. -- --- include/linux

[PATCH v2 2/8] platform/chrome: cros_ec_typec: Correct the Thunderbolt rounded/non-rounded cable support

2020-11-13 Thread Utkarsh Patel
Thunderbolt rounded/non-rounded cable support is two bits value. Correcting it as per the Thunderbolt 3 cable discover mode VDO changes done in the Thunderbolt 3 alternate mode header. Signed-off-by: Utkarsh Patel -- Changes in v2: - Removed the fixes tag as there is no functional implication

[PATCH v2 6/8] platform/chrome: cros_ec_typec: Use Thunderbolt 3 cable discover mode VDO in USB4 mode

2020-11-13 Thread Utkarsh Patel
Signed-off-by: Utkarsh Patel -- Changes in v2: - No change. -- --- drivers/platform/chrome/cros_ec_typec.c | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/drivers/platform/chrome/cros_ec_typec.c b/drivers/platform/chrome/cros_ec_typec.c index 8111ed1fc574

[PATCH v2 7/8] usb: typec: intel_pmc_mux: Configure active cable properties for USB4

2020-11-13 Thread Utkarsh Patel
Value received as a part of Thunderbolt 3 cable discover mode VDO needs to be configured in the USB4 mode for the Thunderbolt rounded support and active cable plug link training. Suggested-by: Heikki Krogerus Signed-off-by: Utkarsh Patel -- Changes in v2: - No change. -- --- drivers/usb/typec

[PATCH v2 4/8] usb: typec: Remove one bit support for the Thunderbolt rounded/non-rounded cable

2020-11-13 Thread Utkarsh Patel
Two bits support for the Thunderbolt rounded/non-rounded cable has been added to the header file. Hence, removing unused TBT_CABLE_ROUNDED definition from the header file. Signed-off-by: Utkarsh Patel -- changes in v2: - Removed the fixes tag as there is no functional implication

[PATCH v2 8/8] usb: typec: Remove active_link_training variable from Enter_USB message

2020-11-13 Thread Utkarsh Patel
Thunderbolt 3 cable discover mode VDO support has been added as part of Enter_USB message to fill details of active cable plug link training. Hence, removing unused variable active_link_training from Enter_USB message data structure. Signed-off-by: Utkarsh Patel -- Changes in v2: - No change

[PATCH v2 1/8] usb: typec: Correct the bit values for the Thunderbolt rounded/non-rounded cable support

2020-11-13 Thread Utkarsh Patel
Rounded and non-rounded Thunderbolt cables are represented by two bits as per USB Type-C Connector specification v2.0 section F.2.6. Corrected that in the Thunderbolt 3 cable discover mode VDO. Signed-off-by: Utkarsh Patel -- Changes in v2: - Removed the fixes tag as there is no functional

[PATCH v2 3/8] usb: typec: intel_pmc_mux: Configure Thunderbolt cable generation bits

2020-11-13 Thread Utkarsh Patel
Thunderbolt cable generation bits received as a part of Thunderbolt 3 cable discover mode VDO needs to be configured for Thunderbolt rounded and non-rounded cable support in the Thunderbolt alternate mode. Signed-off-by: Utkarsh Patel -- Changes in v2: - No change. -- --- drivers/usb/typec/mux

[PATCH 1/8] usb: typec: Correct the bit values for the Thunderbolt rounded/non-rounded cable support

2020-11-09 Thread Utkarsh Patel
Signed-off-by: Utkarsh Patel --- include/linux/usb/typec_tbt.h | 5 + 1 file changed, 5 insertions(+) diff --git a/include/linux/usb/typec_tbt.h b/include/linux/usb/typec_tbt.h index 47c2d501ddce..aad648d14bb3 100644 --- a/include/linux/usb/typec_tbt.h +++ b/include/linux/usb/typec_tbt.h @@ -40

[PATCH 7/8] usb: typec: intel_pmc_mux: Configure active cable properties for USB4

2020-11-09 Thread Utkarsh Patel
Value received as a part of Thunderbolt 3 cable discover mode VDO needs to be configured in the USB4 mode for the Thunderbolt rounded support and active cable plug link training. Suggested-by: Heikki Krogerus Signed-off-by: Utkarsh Patel --- drivers/usb/typec/mux/intel_pmc_mux.c | 18

[PATCH 5/8] usb: typec: Use Thunderbolt 3 cable discover mode VDO in Enter_USB message

2020-11-09 Thread Utkarsh Patel
USB4 also uses same cable properties as Thunderbolt 3 so use Thunderbolt 3 cable discover mode VDO to fill details such as active cable plug link training and cable rounded support. Suggested-by: Heikki Krogerus Signed-off-by: Utkarsh Patel --- include/linux/usb/typec.h | 2 ++ 1 file changed

[PATCH 6/8] platform/chrome: cros_ec_typec: Use Thunderbolt 3 cable discover mode VDO in USB4 mode

2020-11-09 Thread Utkarsh Patel
Signed-off-by: Utkarsh Patel --- drivers/platform/chrome/cros_ec_typec.c | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/drivers/platform/chrome/cros_ec_typec.c b/drivers/platform/chrome/cros_ec_typec.c index 8111ed1fc574..b7416e82c3b3 100644 --- a/drivers

[PATCH 8/8] usb: typec: Remove active_link_training variable from Enter_USB message

2020-11-09 Thread Utkarsh Patel
Thunderbolt 3 cable discover mode VDO support has been added as part of Enter_USB message to fill details of active cable plug link training. Hence, removing unused variable active_link_training from Enter_USB message data structure. Signed-off-by: Utkarsh Patel --- include/linux/usb/typec.h

[PATCH 3/8] usb: typec: intel_pmc_mux: Configure Thunderbolt cable generation bits

2020-11-09 Thread Utkarsh Patel
Thunderbolt cable generation bits received as a part of Thunderbolt 3 cable discover mode VDO needs to be configured for Thunderbolt rounded and non-rounded cable support in the Thunderbolt alternate mode. Signed-off-by: Utkarsh Patel --- drivers/usb/typec/mux/intel_pmc_mux.c | 3 +++ 1 file

[PATCH 2/8] platform/chrome: cros_ec_typec: Correct the Thunderbolt rounded/non-rounded cable support

2020-11-09 Thread Utkarsh Patel
Thunderbolt rounded/non-rounded cable support is two bits value. Correcting it as per the Thunderbolt 3 cable discover mode VDO changes done in the Thunderbolt 3 alternate mode header. Fixes: 5b30bd35aab4 ("platform/chrome: cros_ec_typec: Add TBT compat support") Signed-off-by: Utk

[PATCH 4/8] usb: typec: Remove one bit support for the Thunderbolt rounded/non-rounded cable

2020-11-09 Thread Utkarsh Patel
Two bits support for the Thunderbolt rounded/non-rounded cable has been added to the header file. Hence, removing unused TBT_CABLE_ROUNDED definition from the header file. Fixes: ca469c292edc ("usb: typec: Add definitions for Thunderbolt 3 Alternate Mode") Signed-off-by: Utk

[PATCH 0/8] Thunderbolt3/USB4 cable rounded and active cable plug link training support

2020-11-09 Thread Utkarsh Patel
This patch series adds the support for Thunderbolt3/USB4 rounded and non-rounded frequencies cables and fixes the active cable plug link training support. Utkarsh Patel (8): usb: typec: Correct the bit values for the Thunderbolt rounded/non-rounded cable support platform/chrome