linux/drivers/input/touchscreen
Dmitry Torokhov a6ac4e24c1 Input: mms114 - fix touch indexing for MMS134S and MMS136
The MMS134S and MMS136 touch controllers have an event size of 6 bytes
rather than 8 bytes. When __mms114_read_reg() reads the touch data
packet from the device into the touch buffer, the events are packed
tightly at 6-byte intervals. However, the driver iterates through the
events using standard C array indexing (touch[index]), where each
element is sizeof(struct mms114_touch) (8 bytes) apart. As a result, any
touch events beyond the first one are read from incorrect offsets and
parsed improperly.

Fix this by explicitly calculating the byte offset for each touch event
based on the device's specific event size.

Fixes: 53fefdd1d3 ("Input: mms114 - support MMS136")
Fixes: ab10867819 ("Input: mms114 - support MMS134S")
Reported-by: sashiko-bot@kernel.org
Assisted-by: Antigravity:gemini-3.5-flash
Reviewed-by: Bryam Vargas <hexlabsecurity@proton.me>
Link: https://patch.msgid.link/20260616050912.1531241-1-dmitry.torokhov@gmail.com
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2026-06-22 23:04:19 -07:00
..
88pm860x-ts.c
ad7877.c
ad7879-i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
ad7879-spi.c
ad7879.c
ad7879.h
ads7846.c Input: ads7846 - don't use scratch for tx_buf when clearing register 2026-06-10 15:47:47 -07:00
apple_z2.c
ar1021_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
atmel_mxt_ts.c Linux 7.1-rc6 2026-05-31 19:43:25 -07:00
auo-pixcir-ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
bcm_iproc_tsc.c
bu21013_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
bu21029_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
chipone_icn8318.c Input: chipone_icn8318 - use guard notation when acquiring mutex 2026-03-24 21:14:22 -07:00
chipone_icn8505.c
colibri-vf50-ts.c
cy8ctma140.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
cy8ctmg110_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
cyttsp_core.c Input: cyttsp - use guard notation when acquiring mutex 2026-03-24 21:14:23 -07:00
cyttsp_core.h
cyttsp_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
cyttsp_spi.c
cyttsp5.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
da9034-ts.c
da9052_tsi.c
dynapro.c
edt-ft5x06.c Input: edt-ft5x06 - fix use-after-free in debugfs teardown 2026-04-19 17:54:06 -07:00
eeti_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
egalax_ts_serial.c
egalax_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
ektf2127.c Input: ektf2127 - use guard notation when acquiring mutex 2026-03-24 21:14:24 -07:00
elants_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
elo.c Input: elo - use guard notation when acquiring mutex 2026-03-24 21:14:26 -07:00
exc3000.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
fsl-imx25-tcq.c
fujitsu_ts.c
goodix_berlin_core.c Input: goodix-berlin - report a resolution of 10 units/mm 2026-03-25 09:08:17 -07:00
goodix_berlin_i2c.c
goodix_berlin_spi.c
goodix_berlin.h
goodix_fwupload.c Input: goodix - switch to using cleanup functions in firmware code 2026-03-24 21:14:27 -07:00
goodix.c Input: goodix - clamp the device-reported contact count 2026-06-22 20:44:12 -07:00
goodix.h
gunze.c
hampshire.c
hideep.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
himax_hx852x.c
himax_hx83112b.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
hp680_ts_input.c
htcpen.c
hycon-hy46xx.c Input: hycon-hy46xx - use guard notation when acquiring mutex 2026-03-24 21:14:49 -07:00
hynitron_cstxxx.c
hynitron-cst816x.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
ili210x.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
ilitek_ts_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
imagis.c Input: imagis - use guard notation when acquiring mutex 2026-03-24 21:14:50 -07:00
imx6ul_tsc.c Input: imx6ul_tsc - use guard notation when acquiring mutex 2026-03-24 21:14:50 -07:00
inexio.c
ipaq-micro-ts.c Input: ipaq-micro-ts - use guard notation when acquiring mutex/spinlock 2026-03-24 21:14:51 -07:00
iqs5xx.c Input: iqs5xx - drop unused i2c driver_data 2026-05-30 22:11:56 -07:00
iqs7211.c Input: iqs7211 - use cleanup facility for fwnodes 2026-03-24 21:14:53 -07:00
jornada720_ts.c
Kconfig Input: Add support for Wacom W9000-series penabled touchscreens 2026-05-29 22:31:40 -07:00
lpc32xx_ts.c Input: lpc32xx_ts - use guard notation when acquiring mutex 2026-03-24 21:14:53 -07:00
mainstone-wm97xx.c
Makefile Input: Add support for Wacom W9000-series penabled touchscreens 2026-05-29 22:31:40 -07:00
max11801_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
mc13783_ts.c
melfas_mip4.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
migor_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
mms114.c Input: mms114 - fix touch indexing for MMS134S and MMS136 2026-06-22 23:04:19 -07:00
msg2638.c Input: msg2638 - use guard notation when acquiring mutex 2026-03-24 21:14:56 -07:00
mtouch.c
mxs-lradc-ts.c Input: mxs-lradc-ts - use guard notation when acquiring spinlock 2026-03-25 07:53:57 -07:00
novatek-nvt-ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
penmount.c
pixcir_i2c_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
raspberrypi-ts.c
raydium_i2c_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
resistive-adc-touch.c
rohm_bu21023.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
s6sy761.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
silead.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
sis_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
st1232.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
stmfts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
stmpe-ts.c
sun4i-ts.c
sur40.c Input: sur40 - use guard notation when acquiring spinlock 2026-03-25 07:53:59 -07:00
surface3_spi.c
sx8654.c Input: sx8654 - use IRQF_NOAUTOEN when requesting interrupt 2026-03-25 07:53:59 -07:00
ti_am335x_tsc.c
touchit213.c
touchright.c
touchwin.c Input: touchwin - reset the packet index on every complete packet 2026-06-14 13:58:16 -07:00
tps6507x-ts.c
ts4800-ts.c
tsc40.c
tsc200x-core.c
tsc200x-core.h
tsc2004.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
tsc2005.c
tsc2007_core.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
tsc2007_iio.c Input: tsc2007 - use guard notation when acquiring mutexes 2026-03-25 07:53:59 -07:00
tsc2007.h
usbtouchscreen.c Input: usbtouchscreen - clamp NEXIO data_len/x_len to URB buffer size 2026-04-26 21:00:25 -07:00
wacom_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
wacom_w8001.c
wacom_w9000.c Input: Add support for Wacom W9000-series penabled touchscreens 2026-05-29 22:31:40 -07:00
wdt87xx_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
wm97xx-core.c Input: wm97xx - use guard notation when acquiring mutex 2026-03-25 07:54:00 -07:00
wm831x-ts.c
wm9705.c
wm9712.c
wm9713.c
zet6223.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
zforce_ts.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
zinitix.c Input: zinitix - use guard notation when acquiring mutex 2026-03-25 07:54:00 -07:00