From: Zhang Hewei The PD message duplicate-check and the SOFT_RESET state handling treat the SOP and SOP' channels differently: tcpm_pd_rx_handler() exempts PD_CTRL_SOFT_RESET from the MessageID duplicate check on the SOP path (USB PD spec 6.6.1.2 note: a Soft_Reset message always carries MessageID zero, so the duplicate check must not drop it), but the SOP' branch of the same switch has no such exemption. A cable that sends a second Soft Reset over SOP' (MessageID zero again) has that message silently dropped by the rx_msgid_prime comparison, and the cable-side re-negotiation stalls. Exempt Soft Reset on the SOP' path the same way the SOP path does. Found by code inspection; a software TCPC stub was built for the responder path. Fixes: 6bd181ba60e1 ("usb: typec: tcpm: add control message support to sop'") Cc: stable@vger.kernel.org Signed-off-by: Zhang Hewei diff --git a/drivers/usb/typec/tcpm/tcpm.c b/drivers/usb/typec/tcpm/tcpm.c index bb90211..89e280b 100644 --- a/drivers/usb/typec/tcpm/tcpm.c +++ b/drivers/usb/typec/tcpm/tcpm.c @@ -4200,7 +4200,8 @@ static void tcpm_pd_rx_handler(struct kthread_work *work) */ switch (rx_sop_type) { case TCPC_TX_SOP_PRIME: - if (msgid == port->rx_msgid_prime) + if (msgid == port->rx_msgid_prime && + type != PD_CTRL_SOFT_RESET) goto done; port->rx_msgid_prime = msgid; break; -- 2.39.5 (Apple Git-154)