CVE-2026-98859: HID: multitouch: stop the release timer from being rearmed on remove
In the Linux kernel, the following vulnerability has been resolved:
HID: multitouch: stop the release timer from being rearmed on remove
mtremove() quiesces the sticky-finger timer before stopping the hardware:
timerdeletesync(&td->releasetimer);
sysfsremovegroup(&hdev->dev.kobj, &mtattributegroup); hidhwstop(hdev);
timerdeletesync() waits for a running callback and dequeues the timer, but it does not stop the timer from being armed again. The transport is still delivering reports at that point, and the report path rearms it:
if (app->quirks & MTQUIRKSTICKYFINGERS) { if (td->mtioflags & MTIOSLOTSMASK) modtimer(&td->releasetimer, jiffies + msecstojiffies(100));
A report that arrives after timerdeletesync() has returned therefore leaves the timer queued. td is allocated with devmkzalloc() against hdev->dev, so it is freed when the driver is unbound, after mtremove() returns. When the timer fires afterwards, mtexpiredtimeout() dereferences the freed td:
struct mtdevice td = timercontainerof(td, t, releasetimer); struct hiddevice hdev = td->hdev;
if (testandsetbitlock(MTIOFLAGSRUNNING, &td->mtioflags))
Simply moving the teardown after hidhwstop() does not fix this on its own, because mtexpiredtimeout() calls mtreleasecontacts(), which walks hdev->inputs; the timer still has to be quiesced before hidhwstop() tears the input devices down.
Use timershutdownsync() instead, which additionally makes any later modtimer() a no-op, so neither ordering constraint has to be traded off against the other. This is the final-teardown pattern the function was introduced for, and hid-wiimote already uses it for the same reason.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In HID multitouch mt_remove(), replace timer_delete_sync(&td->release_timer) with timer_shutdown_sync(&td->release_timer) before hid_hw_stop(hdev), preventing the release timer from being rearmed during teardown.
Event History
Frequently Asked Questions
Which systems are exposed to this issue?
Systems using the Linux kernel HID multitouch driver are exposed when the sticky-finger quirk is active. The vulnerable condition involves removal or unbinding of the HID device while the transport can still deliver reports.
What must happen for exploitation or failure to occur?
A report must arrive after the release timer has been deleted during device removal, causing the report path to arm the timer again. Once the driver is unbound and its device data is freed, the subsequently firing timer can dereference freed memory.
How can I determine whether a kernel contains the resolution?
Check the kernel source or applied stable patches for the referenced commits: 1f1bd9a3117f082eb891c0986c4f0e04cd974c9a, 0c19a6c1d25fd5ed66d1f80dc6f6e56cc1f0a787, or a0125ca86e405b8a704e96157a6c10ca51087652. The resolved behavior must prevent the release timer from being rearmed after teardown begins.