linux-stable/drivers/input
Nathan Chancellor 470a271627 Input: ads7846 - increase xfer array size in 'struct ser_req'
Clang warns (or errors with CONFIG_WERROR=y, trimmed for brevity):

  drivers/input/touchscreen/ads7846.c:412:2: error: array index 6 is past the end of the array (that has type 'struct spi_transfer[6]') [-Werror,-Warray-bounds]
    412 |         req->xfer[6].tx_buf = &req->scratch;
        |         ^         ~
  ...
  drivers/input/touchscreen/ads7846.c:416:2: error: array index 7 is past the end of the array (that has type 'struct spi_transfer[6]') [-Werror,-Warray-bounds]
    416 |         req->xfer[7].rx_buf = &req->scratch;
        |         ^         ~
  drivers/input/touchscreen/ads7846.c:334:2: note: array 'xfer' declared here
    334 |         struct spi_transfer     xfer[6];
        |         ^

Increase the size of xfer in 'struct ser_req' to ensure that there is
enough space for all necessary members and there are no out of bounds
accesses, clearing up the warning.

Fixes: 781a07da9b ("Input: ads7846 - add dummy command register clearing cycle")
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Reviewed-by: Marek Vasut <marex@denx.de>
Link: https://lore.kernel.org/r/20241111-input-ads7846-increase-xfer-array-size-v1-1-06cd92e9f20f@kernel.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2024-11-14 18:04:52 -08:00
..
gameport Driver core changes for 6.11-rc1 2024-07-25 10:42:22 -07:00
joystick Input: xpad - use guard notation when acquiring mutex and spinlock 2024-10-03 09:07:32 -07:00
keyboard Input: maple_keyb - use guard notation when acquiring mutex 2024-11-05 14:17:32 -08:00
misc Input: sparcspkr - use cleanup facility for device_node 2024-10-22 13:58:39 -07:00
mouse Input: synaptics - fix a typo 2024-11-04 21:49:05 -08:00
rmi4 Input: synaptics-rmi4 - switch to using cleanup functions in F34 2024-11-04 21:50:06 -08:00
serio Input: i8042 - fix typo dublicate to duplicate 2024-11-07 22:09:29 -08:00
tablet Input: pegasus_notetaker - use guard notation when acquiring mutex 2024-10-03 09:10:37 -07:00
tests Input updates for v6.11-rc0 2024-07-19 16:51:39 -07:00
touchscreen Input: ads7846 - increase xfer array size in 'struct ser_req' 2024-11-14 18:04:52 -08:00
apm-power.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
evbug.c Input: evbug - remove an empty comment block 2021-05-24 21:06:39 -07:00
evdev.c Input: evdev - limit amount of data for writes 2024-08-23 23:51:14 -07:00
ff-core.c Input: ff-core - prefer struct_size over open coded arithmetic 2024-04-30 14:04:31 -07:00
ff-memless.c input: drop empty comment blocks 2022-09-29 16:25:42 -07:00
input-compat.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
input-compat.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
input-core-private.h Input: deactivate MT slots when inhibiting or suspending devices 2022-07-20 11:35:13 -07:00
input-leds.c Input: leds - change config symbol dependency for audio mute trigger 2024-03-03 14:46:06 -08:00
input-mt.c Input: MT - limit max slots 2024-07-29 10:44:48 -07:00
input-poller.c Input: use input_device_enabled() 2020-12-02 22:10:33 -08:00
input-poller.h Input: add support for polling to input devices 2019-08-20 12:04:07 -07:00
input.c Input: introduce notion of passive observers for input handlers 2024-11-05 14:19:47 -08:00
joydev.c Input: joydev - fix comment typo 2022-09-25 00:57:25 -07:00
Kconfig Input: tests - modular KUnit tests should not depend on KUNIT=y 2023-05-02 10:39:00 -07:00
Makefile Input: Add KUnit tests for some of the input core helper functions 2023-04-01 22:47:04 -07:00
matrix-keymap.c Input: matrix-keymap - switch to using __free() cleanup facility 2024-08-29 10:59:30 -07:00
mousedev.c *: convert stream-like files -> stream_open, even if they use noop_llseek 2019-07-14 16:09:19 +03:00
sparse-keymap.c Input: Use fallthrough pseudo-keyword 2020-07-07 11:25:54 -07:00
touchscreen.c Input: touchscreen - avoid bitwise vs logical OR warning 2021-10-15 22:22:54 -07:00
vivaldi-fmap.c Input: add missing MODULE_DESCRIPTION() macros 2024-06-09 14:38:48 -07:00