WSL2-Linux-Kernel/drivers/usb
Badhri Jagan Sridharan c2372b1559 usb: typec: tcpm: Fix response to vsafe0V event
commit 4270d2b484 upstream.

Do not transition to SNK_UNATTACHED state when receiving vsafe0v event
while in SNK_HARD_RESET_WAIT_VBUS. Ignore VBUS off events as well as
in some platforms VBUS off can be signalled more than once.

[143515.364753] Requesting mux state 1, usb-role 2, orientation 2
[143515.365520] pending state change SNK_HARD_RESET_SINK_OFF -> SNK_HARD_RESET_SINK_ON @ 650 ms [rev3 HARD_RESET]
[143515.632281] CC1: 0 -> 0, CC2: 3 -> 0 [state SNK_HARD_RESET_SINK_OFF, polarity 1, disconnected]
[143515.637214] VBUS on
[143515.664985] VBUS off
[143515.664992] state change SNK_HARD_RESET_SINK_OFF -> SNK_HARD_RESET_WAIT_VBUS [rev3 HARD_RESET]
[143515.665564] VBUS VSAFE0V
[143515.665566] state change SNK_HARD_RESET_WAIT_VBUS -> SNK_UNATTACHED [rev3 HARD_RESET]

Fixes: 28b43d3d74 ("usb: typec: tcpm: Introduce vsafe0v for vbus")
Cc: <stable@vger.kernel.org>
Signed-off-by: Badhri Jagan Sridharan <badhri@google.com>
Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Link: https://lore.kernel.org/r/20230712085722.1414743-1-badhri@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-08-16 18:21:59 +02:00
..
atm
c67x00
cdns3 usb: cdns3: fix incorrect calculation of ep_buf_size when more than one config 2023-08-03 10:22:42 +02:00
chipidea usb: chipidea: fix missing goto in `ci_hdrc_probe` 2023-05-11 23:00:33 +09:00
class USB: usbtmc: Fix direction for 0-length ioctl control messages 2023-05-24 17:36:52 +01:00
common usb: common: usb-conn-gpio: Prevent bailing out if initial role is none 2023-08-16 18:21:59 +02:00
core USB: quirks: add quirk for Focusrite Scarlett 2023-08-03 10:22:42 +02:00
dwc2 usb: dwc2: Fix some error handling paths 2023-07-23 13:47:21 +02:00
dwc3 usb: dwc3: Properly handle processing of pending events 2023-08-16 18:21:59 +02:00
early usb: early: xhci-dbc: Fix a potential out-of-bound memory access 2023-03-10 09:39:39 +01:00
gadget USB: gadget: Fix the memory leak in raw_gadget driver 2023-08-03 10:22:40 +02:00
host Revert "xhci: add quirk for host controllers that don't update endpoint DCS" 2023-08-03 10:22:43 +02:00
image
isp1760 usb: isp1760: Fix out-of-bounds array access 2022-06-09 10:22:27 +02:00
misc USB: sisusbvga: Add endpoint checks 2023-05-30 13:55:31 +01:00
mon usb: mon: make mmapped memory read only 2022-10-12 09:53:28 +02:00
mtu3 usb: mtu3: fix kernel panic at qmu transfer done irq handler 2023-05-11 23:00:33 +09:00
musb Revert "usb: common: usb-conn-gpio: Set last role to unknown before initial detection" 2023-07-23 13:47:25 +02:00
phy usb: phy: phy-tahvo: fix memory leak in tahvo_usb_probe() 2023-07-23 13:47:23 +02:00
renesas_usbhs usb: renesas: Fix refcount leak bug 2022-08-25 11:40:33 +02:00
roles Revert "usb: common: usb-conn-gpio: Set last role to unknown before initial detection" 2023-07-23 13:47:25 +02:00
serial USB: serial: simple: sort driver entries 2023-08-03 10:22:41 +02:00
storage usb-storage: alauda: Fix uninit-value in alauda_check_media() 2023-08-16 18:21:59 +02:00
typec usb: typec: tcpm: Fix response to vsafe0V event 2023-08-16 18:21:59 +02:00
usbip usb: usbip: add missing device lock on tweak configuration cmd 2022-06-14 18:36:04 +02:00
Kconfig
Makefile
usb-skeleton.c