diff options
author | Maximilian Weigand <[email protected]> | 2023-05-01 17:07:49 -0700 |
---|---|---|
committer | Dmitry Torokhov <[email protected]> | 2023-05-01 17:30:31 -0700 |
commit | 529de2f1ca3f0898c0d905b7d355a43dce1de7dc (patch) | |
tree | f4ec796541ef4336644bb24281636134a0fa8250 | |
parent | 9a87ffc99ec8eb8d35eed7c4f816d75f5cc9662e (diff) |
Input: cyttsp5 - fix array length
The cmd array should be initialized with the proper command size and not
with the actual command value that is sent to the touchscreen.
Signed-off-by: Maximilian Weigand <[email protected]>
Reviewed-by: Alistair Francis <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Fixes: 5b0c03e24a06 ("Input: Add driver for Cypress Generation 5 touchscreen")
Cc: [email protected]
Signed-off-by: Dmitry Torokhov <[email protected]>
-rw-r--r-- | drivers/input/touchscreen/cyttsp5.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/input/touchscreen/cyttsp5.c b/drivers/input/touchscreen/cyttsp5.c index 30102cb80fac..3c9d07218f48 100644 --- a/drivers/input/touchscreen/cyttsp5.c +++ b/drivers/input/touchscreen/cyttsp5.c @@ -560,7 +560,7 @@ static int cyttsp5_hid_output_get_sysinfo(struct cyttsp5 *ts) static int cyttsp5_hid_output_bl_launch_app(struct cyttsp5 *ts) { int rc; - u8 cmd[HID_OUTPUT_BL_LAUNCH_APP]; + u8 cmd[HID_OUTPUT_BL_LAUNCH_APP_SIZE]; u16 crc; put_unaligned_le16(HID_OUTPUT_BL_LAUNCH_APP_SIZE, cmd); |