CVE-2026-143437: thermal/drivers/sprd: validate the sensor id from the device tree

Published Dec 5, 2026
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

thermal/drivers/sprd: validate the sensor id from the device tree

sprdthmprobe() reads each sensor child node's "reg" property into sen->id and uses it without validation: to compute the sensor's register offsets in sprdthmsensorinit(), as the thermal zone id, and finally as an index into thm->sensor[], which has SPRDTHMMAXSENSOR (8) entries:

ret = ofpropertyreadu32(senchild, "reg", &sen->id); ... thm->sensor[sen->id] = sen;

Only the number of sensor nodes is checked against SPRDTHMMAXSENSOR. A "reg" value of 8 or more, or one that is negative once stored in the int sen->id, makes the register offsets point outside the sensor range and the final store land outside thm->sensor[], overwriting the fields that follow it in struct sprdthermaldata or other memory.

Reject an out-of-range id right after reading it, before it is used.

This does not address sparse ids, such as a single sensor with id 7: they leave holes in thm->sensor[] that the later loops over 0..nrsensors-1 dereference. That needs a separate fix.

Found by static analysis tool CodeQL.

Affected Software

1 affected component
Linux Linux kernel

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Compensating control

    In sprd_thm_probe(), reject an out-of-range sensor id immediately after reading the device-tree "reg" property, before using it for register offsets, the thermal zone id, or indexing thm->sensor[].

Event History

Dec 5, 2026
CVE Published
via MITRE·01:41 AM
Data Sourced
via MITRE·01:41 AM
Description

Frequently Asked Questions

1

What systems are exposed to this issue?

Systems using the Linux kernel Spreadtrum thermal driver are exposed when their device tree contains sensor child nodes with an invalid "reg" sensor ID. The affected path uses that ID for register-offset calculation and as an index into an eight-entry sensor array.

2

What is required to trigger the memory corruption?

A sensor child node must provide a "reg" value outside the valid sensor range, such as 8 or greater, or a value that becomes negative when stored in the integer sensor ID. The driver must then probe that device-tree configuration.

3

What can be done if the fix cannot be applied immediately?

Ensure every sensor child node's "reg" property is a valid in-range sensor ID for the driver's eight-entry sensor array. Also avoid sparse sensor IDs: although not addressed by this fix, a configuration such as only sensor ID 7 can leave holes that later driver loops dereference.

4

How can I check whether a device-tree configuration is affected?

Inspect the Spreadtrum thermal sensor child nodes and review their "reg" values. Values of 8 or higher, or values that become negative after storage in the driver's integer sensor ID, are affected; sparse IDs can also cause a separate null-dereference issue.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203