Badhri Jagan Sridharan
4f9c0a7c27
usb: typec: altmodes/displayport: fix pin_assignment_show
commit d8f28269dd4bf9b55c3fb376ae31512730a96fce upstream.
This patch fixes negative indexing of buf array in pin_assignment_show
when get_current_pin_assignments returns 0 i.e. no compatible pin
assignments are found.
BUG: KASAN: use-after-free in pin_assignment_show+0x26c/0x33c
...
Call trace:
dump_backtrace+0x110/0x204
dump_stack_lvl+0x84/0xbc
print_report+0x358/0x974
kasan_report+0x9c/0xfc
__do_kernel_fault+0xd4/0x2d4
do_bad_area+0x48/0x168
do_tag_check_fault+0x24/0x38
do_mem_abort+0x6c/0x14c
el1_abort+0x44/0x68
el1h_64_sync_handler+0x64/0xa4
el1h_64_sync+0x78/0x7c
pin_assignment_show+0x26c/0x33c
dev_attr_show+0x50/0xc0
Fixes: 0e3bb7d689 ("usb: typec: Add driver for DisplayPort alternate mode")
Cc: [email protected]
Signed-off-by: Badhri Jagan Sridharan <[email protected]>
Reviewed-by: Heikki Krogerus <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
2023-05-30 12:44:06 +01:00 |
| .. |
|
atm
|
|
|
|
c67x00
|
|
|
|
cdns3
|
usb: cdns3: Fix issue with using incorrect PCI device function
|
2023-04-05 11:16:40 +02:00 |
|
chipidea
|
usb: chipidea: fix missing goto in ci_hdrc_probe
|
2023-05-17 11:35:49 +02:00 |
|
class
|
USB: usbtmc: Fix direction for 0-length ioctl control messages
|
2023-05-30 12:44:06 +01:00 |
|
common
|
Revert "usb: ulpi: defer ulpi_register on ulpi_read_id timeout"
|
2023-01-18 11:42:06 +01:00 |
|
core
|
USB: core: Don't hold device lock while reading the "descriptors" sysfs file
|
2023-03-03 11:41:49 +01:00 |
|
dwc2
|
usb: dwc2: fix wrong order of phy_power_on and phy_init
|
2022-09-15 12:04:52 +02:00 |
|
dwc3
|
usb: dwc3: debugfs: Resume dwc3 before accessing registers
|
2023-05-30 12:44:06 +01:00 |
|
early
|
|
|
|
gadget
|
usb: gadget: udc: renesas_usb3: Fix use after free bug in renesas_usb3_remove due to race condition
|
2023-05-17 11:35:46 +02:00 |
|
host
|
USB: UHCI: adjust zhaoxin UHCI controllers OverCurrent bit value
|
2023-05-30 12:44:06 +01:00 |
|
image
|
|
|
|
isp1760
|
|
|
|
misc
|
USB: misc: iowarrior: fix up header size for USB_DEVICE_ID_CODEMERCS_IOW100
|
2023-01-24 07:18:00 +01:00 |
|
mon
|
usb: mon: make mmapped memory read only
|
2022-10-15 07:54:38 +02:00 |
|
mtu3
|
usb: mtu3: fix kernel panic at qmu transfer done irq handler
|
2023-05-17 11:35:49 +02:00 |
|
musb
|
usb: musb: remove extra check in musb_gadget_vbus_draw
|
2023-01-18 11:40:49 +01:00 |
|
phy
|
|
|
|
renesas_usbhs
|
|
|
|
roles
|
usb: roles: fix of node refcount leak in usb_role_switch_is_parent()
|
2023-01-18 11:41:24 +01:00 |
|
serial
|
USB: serial: option: add UNISOC vendor and TOZED LT70C product
|
2023-05-17 11:35:31 +02:00 |
|
storage
|
usb-storage: fix deadlock when a scsi command timeouts more than once
|
2023-05-30 12:44:06 +01:00 |
|
typec
|
usb: typec: altmodes/displayport: fix pin_assignment_show
|
2023-05-30 12:44:06 +01:00 |
|
usbip
|
|
|
|
Kconfig
|
|
|
|
Makefile
|
|
|
|
usb-skeleton.c
|
|
|