CVE-2026-142963: iio: accel: kxsd9: Fix potential use-after-free on removal
In the Linux kernel, the following vulnerability has been resolved:
iio: accel: kxsd9: Fix potential use-after-free on removal
Unregistering an IIO device with an active triggered buffer detaches its poll function. Freeing the poll function first can therefore make iiodeviceunregister() access freed memory.
Unregister the device before cleaning up the triggered buffer.
This issue was found by our static analysis tool under development.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In the Linux kernel IIO kxsd9 driver, unregister the device before cleaning up the triggered buffer.
Event History
Frequently Asked Questions
Which systems are exposed to this issue?
Systems using the Linux kernel kxsd9 IIO accelerometer driver are exposed when the device has an active triggered buffer and is being removed or unregistered. The provided data does not describe any network-facing or unprivileged exploitation path.
What condition triggers the unsafe code path?
The condition occurs during device removal when an active IIO triggered buffer is present. The vulnerable cleanup order can free the poll function before device unregistration, after which unregistration may access that freed memory.
What should be done to remediate it?
Update to a Linux kernel release that includes the fix referenced in the supplied stable kernel commits. The correction unregisters the IIO device before cleaning up the triggered buffer.