linux/drivers/input/rmi4
Dmitry Torokhov 2d6d33e45d Input: rmi4 - tolerate short register descriptor structure
Some touchpads (e.g. ThinkPad T14 Gen 1) have buggy firmware that reports
a register descriptor structure size that is too small for the number of
registers it claims to have in the presence map. The remaining bytes in
the structure are 0, which with the new strict bounds checking causes the
parser to fail with -EIO, aborting the device probe.

Tolerate such short reads by dropping the remaining (unparseable or
0-size) registers from the list instead of failing the probe,
preventing the driver from trying to use them.

Fixes: 0adb483fbf ("Input: rmi4 - refactor register descriptor parsing")
Reported-by: Barry K. Nathan <barryn@pobox.com>
Tested-by: Barry K. Nathan <barryn@pobox.com>
Cc: stable@vger.kernel.org
Assisted-by: Antigravity:gemini-3.5-flash
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2026-06-26 22:23:40 -07:00
..
Kconfig Input: synaptics-rmi4 - add support for F1A 2025-07-27 01:41:19 -07:00
Makefile Input: synaptics-rmi4 - add support for F1A 2025-07-27 01:41:19 -07:00
rmi_2d_sensor.c Input: include export.h in modules using EXPORT_SYMBOL*() 2025-08-21 12:00:59 -07:00
rmi_2d_sensor.h Input: rmi4 - change reg_size type to u32 2026-06-11 22:39:29 -07:00
rmi_bus.c Input: rmi4 - use kzalloc_flex() for struct rmi_function 2026-06-11 22:39:28 -07:00
rmi_bus.h Input: rmi4 - refactor function allocation and registration 2026-06-11 22:39:28 -07:00
rmi_driver.c Input: rmi4 - tolerate short register descriptor structure 2026-06-26 22:23:40 -07:00
rmi_driver.h Input: rmi4 - change reg_size type to u32 2026-06-11 22:39:29 -07:00
rmi_f01.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
rmi_f1a.c Input: synaptics-rmi4 - add support for F1A 2025-07-27 01:41:19 -07:00
rmi_f03.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
rmi_f3a.c Input: synaptics-rmi4 - bound the F3A keymap to the GPIO count 2026-06-25 17:46:20 -07:00
rmi_f11.c Input: rmi4 - change reg_size type to u32 2026-06-11 22:39:29 -07:00
rmi_f12.c Input: rmi4 - update formatting in F12 2026-06-11 22:39:30 -07:00
rmi_f21.c Input: synaptics-rmi4 - add support for Forcepads (F21) 2025-07-27 01:24:21 -07:00
rmi_f30.c Input: synaptics-rmi4 - bound the F30 keymap to the GPIO/LED count 2026-06-25 17:46:20 -07:00
rmi_f34.c Input: synaptics-rmi - fix crash with unsupported versions of F34 2025-05-19 11:58:36 -07:00
rmi_f34.h Input: synaptics-rmi4 - remove unneeded struct register_offset 2022-09-23 13:00:13 -07:00
rmi_f34v7.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
rmi_f54.c Input: synaptics-rmi4 - fix a locking bug in an error path 2026-02-23 15:07:58 -08:00
rmi_f55.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
rmi_i2c.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
rmi_smbus.c Input: Use named initializers for arrays of i2c_device_data 2026-05-30 22:10:47 -07:00
rmi_spi.c Input: synaptics-rmi4 - follow renaming of SPI "master" to "controller" 2024-02-08 11:54:39 +00:00