linux-stable/include/linux/usb
RD Babiera f236433064 usb: typec: bus: verify partner exists in typec_altmode_attention
Some usb hubs will negotiate DisplayPort Alt mode with the device
but will then negotiate a data role swap after entering the alt
mode. The data role swap causes the device to unregister all alt
modes, however the usb hub will still send Attention messages
even after failing to reregister the Alt Mode. type_altmode_attention
currently does not verify whether or not a device's altmode partner
exists, which results in a NULL pointer error when dereferencing
the typec_altmode and typec_altmode_ops belonging to the altmode
partner.

Verify the presence of a device's altmode partner before sending
the Attention message to the Alt Mode driver.

Fixes: 8a37d87d72 ("usb: typec: Bus type for alternate modes")
Cc: stable@vger.kernel.org
Signed-off-by: RD Babiera <rdbabiera@google.com>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20230814180559.923475-1-rdbabiera@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-08-22 14:44:28 +02:00
..
audio-v2.h
audio-v3.h
audio.h
c67x00.h
ccid.h
cdc-wdm.h
cdc.h
cdc_ncm.h
ch9.h USB: Remove remnants of Wireless USB and UWB 2023-08-09 14:17:06 +02:00
chipidea.h usb: chipidea: add workaround for chipidea PEC bug 2023-08-09 14:16:06 +02:00
composite.h USB: Remove remnants of Wireless USB and UWB 2023-08-09 14:17:06 +02:00
ehci-dbgp.h
ehci_def.h
ehci_pdriver.h
ezusb.h
functionfs.h
g_hid.h
gadget.h usb: gadget: Add function wakeup support 2023-03-29 10:27:01 +02:00
gadget_configfs.h
hcd.h USB: Remove remnants of Wireless USB and UWB 2023-08-09 14:17:06 +02:00
input.h
iowarrior.h
irda.h
isp116x.h
isp1301.h
isp1362.h
m66592.h
midi-v2.h ALSA: usb-audio: Use __le16 for 16bit USB descriptor fields 2023-06-05 16:48:54 +02:00
musb-ux500.h
musb.h ARM/musb: omap2: Remove global GPIO numbers from TUSB6010 2023-05-24 15:01:59 +02:00
net2280.h
of.h
ohci_pdriver.h
onboard_hub.h
otg-fsm.h
otg.h
pd.h
pd_ado.h
pd_bdo.h
pd_ext_sdb.h
pd_vdo.h
phy.h usb: phy: add usb phy notify port status API 2023-07-26 06:38:14 +02:00
phy_companion.h
quirks.h
r8a66597.h
r8152.h
renesas_usbhs.h
rndis_host.h
role.h Revert "usb: common: usb-conn-gpio: Set last role to unknown before initial detection" 2023-06-15 11:30:35 +02:00
rzv2m_usb3drd.h usb: gadget: Add support for RZ/V2M USB3DRD driver 2023-01-25 15:48:16 +01:00
serial.h USB: serial: return errors from break handling 2023-06-07 17:00:23 +02:00
sl811.h
storage.h
tcpci.h usb: typec: tcpci: Add callback for evaluating contaminant presence 2023-01-17 17:29:23 +01:00
tcpm.h usb: typec: tcpm: Add callbacks to mitigate wakeups due to contaminant 2023-01-17 17:29:23 +01:00
tegra_usb_phy.h
typec.h usb: typec: Add partner PD object wrapper 2022-11-29 08:56:09 +01:00
typec_altmode.h usb: typec: bus: verify partner exists in typec_altmode_attention 2023-08-22 14:44:28 +02:00
typec_dp.h
typec_mux.h usb: typec: mux: fix static inline syntax error 2023-06-01 07:09:45 +01:00
typec_retimer.h
typec_tbt.h
uas.h
ulpi.h
usb338x.h
usb_phy_generic.h
usbnet.h
uvc.h usb: uvc: use v4l2_fill_fmtdesc instead of open coded format name 2023-01-31 09:40:43 +01:00
webusb.h usb: gadget: Use correct APIs and data types for UUID handling 2023-01-31 10:37:29 +01:00
xhci-dbgp.h