HIGH Introduced in 6.18
clocksource IrqHandler UAF
CVE-2026-89769
CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
KernelScan AI6.4MEDIUM
01Description
In the Linux kernel, the following vulnerability has been resolved: clocksource/drivers/nxp-pit: Fix IRQ leak on cpuhp_setup_state error path When cpuhp_setup_state fails after pit_clockevent_per_cpu_init has successfully called request_irq, the error handling jumps directly to out_pit_clocksource_unregister without freeing the registered IRQ. This leaks the IRQ line and, since kfree(pit) follows, leaves a dangling pointer registered as the interrupt handler's dev_id, potentially leading to a use-after-free if the IRQ fires afterwards. Fix it by calling pit_clockevent_per_cpu_exit to properly release the IRQ before falling through to the existing cleanup chain.
02KernelScan AI Analysis
Risk summary
A use-after-free exists in the NXP PIT timer driver's initialization error path on NXP s32g2/s32g3 automotive platforms. If a CPU hotplug setup call fails after an interrupt has been registered, the cleanup frees the timer's private data without releasing the interrupt, leaving a dangling pointer that can be dereferenced when the IRQ fires. This is reachable only during driver initialization on specific automotive hardware and requires inducing an internal kernel allocation failure at a precise point.
Vulnerability analysis
During initialization of the NXP PIT timer driver, if the CPU hotplug setup step fails after an interrupt has already been successfully registered, the error-handling path skips interrupt cleanup and proceeds directly to free the timer's private data structure. This leaves a dangling pointer registered as the interrupt handler's device identifier; if the interrupt fires after the structure has been freed, the handler dereferences freed kernel memory, resulting in a use-after-free. The fix inserts a proper teardown call that releases the registered interrupt before the structure is freed, closing the dangling-pointer window. This code path exists only on NXP s32g2/s32g3 automotive SoCs and is reached during driver probe at boot time or when the module is loaded; triggering it requires inducing an internal kernel allocation failure at a specific point in the initialization sequence, which demands root-level or boot-configuration control of the system.
Lifecycle
03Fix Versions
| Branch | Introduced | Fixed in | Patch commit |
|---|---|---|---|
| mainline | 6.18 | 7.3-rc1 | 05520e035f83 |
| 7.2 | 6.18 | 7.2.4 | cdcd86112324 |
| 6.18 | 6.18 | 6.18.50 | d53c29a89a15 |