3
0
Fork 0
forked from mirrors/linux
kernel/drivers/usb/typec
Jos Wang 659f5d55fe usb: typec: tcpm: PSSourceOffTimer timeout in PR_Swap enters ERROR_RECOVERY
As PD2.0 spec ("6.5.6.2 PSSourceOffTimer"),the PSSourceOffTimer is
used by the Policy Engine in Dual-Role Power device that is currently
acting as a Sink to timeout on a PS_RDY Message during a Power Role
Swap sequence. This condition leads to a Hard Reset for USB Type-A and
Type-B Plugs and Error Recovery for Type-C plugs and return to USB
Default Operation.

Therefore, after PSSourceOffTimer timeout, the tcpm state machine should
switch from PR_SWAP_SNK_SRC_SINK_OFF to ERROR_RECOVERY. This can also
solve the test items in the USB power delivery compliance test:
TEST.PD.PROT.SNK.12 PR_Swap – PSSourceOffTimer Timeout

[1] https://usb.org/document-library/usb-power-delivery-compliance-test-specification-0/USB_PD3_CTS_Q4_2025_OR.zip

Fixes: f0690a25a1 ("staging: typec: USB Type-C Port Manager (tcpm)")
Cc: stable <stable@kernel.org>
Signed-off-by: Jos Wang <joswang@lenovo.com>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Tested-by: Amit Sunil Dhamne <amitsd@google.com>
Link: https://lore.kernel.org/r/20250213134921.3798-1-joswang1221@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-02-14 09:26:44 +01:00
..
altmodes usb: typec: Print err when displayport fails to enter 2024-12-24 08:56:05 +01:00
mux usb: typec: intel_pmc_mux: Silence snprintf() output truncation warning 2024-12-23 18:40:19 +01:00
tcpm usb: typec: tcpm: PSSourceOffTimer timeout in PR_Swap enters ERROR_RECOVERY 2025-02-14 09:26:44 +01:00
tipd USB/Thunderbolt update for 6.12-rc1 2024-09-26 09:45:36 -07:00
ucsi usb: typec: ucsi: Add a macro definition for UCSI v1.0 2025-01-17 12:38:43 +01:00
anx7411.c usb: typec: anx7411: fix OF node reference leaks in anx7411_typec_switch_probe() 2024-12-04 16:25:54 +01:00
bus.c usb: typec: Only use SVID for matching altmodes 2024-12-24 08:56:05 +01:00
bus.h
class.c Driver core and debugfs updates 2025-01-28 12:25:12 -08:00
class.h usb: typec: Add attribute file showing the USB Modes of the partner 2024-10-17 08:41:45 +02:00
hd3ss3220.c usb: typec: hd3ss3220: support configuring role preference based on fwnode property and typec_operation 2024-12-24 08:56:04 +01:00
Kconfig
Makefile
mux.c usb: typec: constify struct class usage 2024-03-02 20:21:06 +01:00
mux.h
pd.c usb: typec: constify the struct device_type usage 2024-02-19 09:35:46 +01:00
pd.h
port-mapper.c
retimer.c usb: typec: constify struct class usage 2024-03-02 20:21:06 +01:00
retimer.h
rt1719.c power: supply: Change usb_types from an array into a bitmask 2024-09-03 23:20:28 +02:00
stusb160x.c usb: typec: stusb160x: Make use of i2c_get_match_data() 2024-10-04 15:12:15 +02:00
wusb3801.c