Re: [PATCH v2] Input: edt-ft5x06 - ignore contacts with an out-of-range slot id

From: Dmitry Torokhov

Date: Thu Jul 23 2026 - 13:59:28 EST


On Thu, Jul 23, 2026 at 08:24:09PM +0700, Alexandre Hamamdjian via B4 Relay wrote:
> From: Alexandre Hamamdjian <azkali.limited@xxxxxxxxx>
>
> The per-contact slot id is taken from the top nibble of the third
> report byte, so it can be any value from 0 to 15. The driver only
> allocates max_support_points MT slots (2 to 10 depending on the
> variant), so a report that carries an id at or above that count - be it
> a genuinely higher-numbered contact or a corrupted byte - is outside the
> range the input core was told about.
>
> input_mt_slot() silently ignores an ABS_MT_SLOT beyond num_slots and
> leaves the current slot unchanged, so the following
> input_mt_report_slot_state()/touchscreen_report_pos() pair is applied to
> whichever slot happened to be selected last, reporting the contact at the
> wrong position. Skip such entries instead.
>
> Signed-off-by: Alexandre Hamamdjian <azkali.limited@xxxxxxxxx>

Applied, thank you.

--
Dmitry