linux-kernelorg-stable/drivers/input/touchscreen
Junjie Cao 248d3a73a0 Input: ti_am335x_tsc - fix off-by-one error in wire_order validation
The current validation 'wire_order[i] > ARRAY_SIZE(config_pins)' allows
wire_order[i] to equal ARRAY_SIZE(config_pins), which causes out-of-bounds
access when used as index in 'config_pins[wire_order[i]]'.

Since config_pins has 4 elements (indices 0-3), the valid range for
wire_order should be 0-3. Fix the off-by-one error by using >= instead
of > in the validation check.

Signed-off-by: Junjie Cao <junjie.cao@intel.com>
Link: https://patch.msgid.link/20251114062817.852698-1-junjie.cao@intel.com
Fixes: bb76dc09dd ("input: ti_am33x_tsc: Order of TSC wires, made configurable")
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2025-12-18 22:00:07 -08:00
..
88pm860x-ts.c
Kconfig
Makefile
ad7877.c
ad7879-i2c.c
ad7879-spi.c
ad7879.c
ad7879.h
ads7846.c
apple_z2.c
ar1021_i2c.c
atmel_mxt_ts.c
auo-pixcir-ts.c
bcm_iproc_tsc.c
bu21013_ts.c
bu21029_ts.c
chipone_icn8318.c
chipone_icn8505.c
colibri-vf50-ts.c
cy8ctma140.c
cy8ctmg110_ts.c
cyttsp5.c
cyttsp_core.c
cyttsp_core.h
cyttsp_i2c.c
cyttsp_spi.c
da9034-ts.c
da9052_tsi.c
dynapro.c
edt-ft5x06.c
eeti_ts.c
egalax_ts.c
egalax_ts_serial.c
ektf2127.c
elants_i2c.c
elo.c
exc3000.c
fsl-imx25-tcq.c
fujitsu_ts.c
goodix.c
goodix.h
goodix_berlin.h
goodix_berlin_core.c
goodix_berlin_i2c.c
goodix_berlin_spi.c
goodix_fwupload.c
gunze.c
hampshire.c
hideep.c
himax_hx852x.c
himax_hx83112b.c
hp680_ts_input.c
htcpen.c
hycon-hy46xx.c
hynitron-cst816x.c
hynitron_cstxxx.c
ili210x.c
ilitek_ts_i2c.c
imagis.c
imx6ul_tsc.c Input: imx6ul_tsc - set glitch threshold by DTS property 2025-09-24 14:21:13 -07:00
inexio.c
ipaq-micro-ts.c
iqs5xx.c
iqs7211.c
jornada720_ts.c
lpc32xx_ts.c
mainstone-wm97xx.c
max11801_ts.c
mc13783_ts.c
melfas_mip4.c
migor_ts.c
mk712.c
mms114.c
msg2638.c
mtouch.c
mxs-lradc-ts.c
novatek-nvt-ts.c
pcap_ts.c
penmount.c
pixcir_i2c_ts.c
raspberrypi-ts.c
raydium_i2c_ts.c
resistive-adc-touch.c
rohm_bu21023.c
s6sy761.c
silead.c
sis_i2c.c
st1232.c
stmfts.c
stmpe-ts.c
sun4i-ts.c
sur40.c
surface3_spi.c
sx8654.c
ti_am335x_tsc.c
touchit213.c
touchright.c
touchwin.c
tps6507x-ts.c
ts4800-ts.c
tsc40.c
tsc200x-core.c
tsc200x-core.h
tsc2004.c
tsc2005.c
tsc2007.h
tsc2007_core.c
tsc2007_iio.c
usbtouchscreen.c
wacom_i2c.c
wacom_w8001.c
wdt87xx_i2c.c
wm97xx-core.c
wm831x-ts.c
wm9705.c
wm9712.c
wm9713.c
zet6223.c
zforce_ts.c
zinitix.c