aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/fpga/altera-fpga2sdram.c
diff options
context:
space:
mode:
authorRD Babiera <[email protected]>2025-06-18 22:49:42 +0000
committerGreg Kroah-Hartman <[email protected]>2025-06-24 14:42:55 +0000
commitaf4db5a35a4ef7a68046883bfd12468007db38f1 (patch)
tree07a620a10bee33b4292d9feb8bbb6d3433c6eb33 /drivers/fpga/altera-fpga2sdram.c
parentusb: cdnsp: Fix issue with CV Bad Descriptor test (diff)
downloadkernel-af4db5a35a4ef7a68046883bfd12468007db38f1.tar.gz
kernel-af4db5a35a4ef7a68046883bfd12468007db38f1.zip
usb: typec: altmodes/displayport: do not index invalid pin_assignments
A poorly implemented DisplayPort Alt Mode port partner can indicate that its pin assignment capabilities are greater than the maximum value, DP_PIN_ASSIGN_F. In this case, calls to pin_assignment_show will cause a BRK exception due to an out of bounds array access. Prevent for loop in pin_assignment_show from accessing invalid values in pin_assignments by adding DP_PIN_ASSIGN_MAX value in typec_dp.h and using i < DP_PIN_ASSIGN_MAX as a loop condition. Fixes: 0e3bb7d6894d ("usb: typec: Add driver for DisplayPort alternate mode") Cc: stable <[email protected]> Signed-off-by: RD Babiera <[email protected]> Reviewed-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]>
Diffstat (limited to 'drivers/fpga/altera-fpga2sdram.c')
0 files changed, 0 insertions, 0 deletions