Skip to content

Commit 24ef83f

Browse files
mastykin-astradtor
authored andcommitted
Input: goodix - fix spurious key release events
The goodix panel sends spurious interrupts after a 'finger up' event, which always cause a timeout. We were exiting the interrupt handler by reporting touch_num == 0, but this was still processed as valid and caused the code to use the uninitialised point_data, creating spurious key release events. Report an error from the interrupt handler so as to avoid processing invalid point_data further. Signed-off-by: Dmitry Mastykin <[email protected]> Reviewed-by: Bastien Nocera <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Dmitry Torokhov <[email protected]>
1 parent 9e1f2d7 commit 24ef83f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/input/touchscreen/goodix.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ static int goodix_ts_read_input_report(struct goodix_ts_data *ts, u8 *data)
345345
* The Goodix panel will send spurious interrupts after a
346346
* 'finger up' event, which will always cause a timeout.
347347
*/
348-
return 0;
348+
return -ENOMSG;
349349
}
350350

351351
static void goodix_ts_report_touch_8b(struct goodix_ts_data *ts, u8 *coor_data)

0 commit comments

Comments
 (0)