CVE-2026-99716: hwmon: (coretemp) Set nr_cores only after core_data allocation succeeds

Published Nov 20, 2026
·
Updated

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

hwmon: (coretemp) Set nrcores only after coredata allocation succeeds

In inittempdata(), pdata->nrcores is populated from topologynumcoresperpackage() before allocating pdata->coredata. If that allocation fails, inittempdata() returns NULL with pdata->coredata still NULL and pdata->nrcores set to a positive value.

coretempaddcore() logs the error without failing coretempcpuonline(), so the CPU still comes online with pdata->hwmondev registered. When the CPU is later taken offline (or the module is unloaded), coretempcpuoffline() calls gettempdata(pd, cpu), which loops up to pdata->nrcores and dereferences the NULL pdata->coredata pointer.

Store the core count in a local variable and assign pdata->nrcores only after pdata->coredata is allocated, preserving the invariant that pdata->nrcores is zero whenever pdata->coredata is NULL.

Affected Software

1 affected componentFixes available
linux/kernel>=6.9.0<7.3.5
7.3.5

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 7.3.5
  2. Compensating control

    In init_temp_data(), store topology_num_cores_per_package() in a local variable and assign pdata->nr_cores only after pdata->core_data allocation succeeds, so pdata->nr_cores remains zero if the allocation fails.

Frequently Asked Questions

1

Under what conditions can this issue be triggered?

The issue requires allocation of the coretemp driver's core_data array to fail during CPU online handling. The affected CPU can still be brought online despite that failure, and a later CPU-offline event or unloading the coretemp module triggers the NULL-pointer dereference.

2

What systems are realistically exposed?

Systems using the Linux kernel coretemp hardware-monitoring driver are exposed when its initialization encounters the described allocation failure. The failure path is specifically relevant to systems that support CPU online/offline operations or where the coretemp module may be unloaded after the failed initialization.

3

What is the effect of a failed allocation before the fix?

The driver can retain a positive core count while its core-data pointer remains NULL. During subsequent cleanup, it iterates using that count and dereferences the NULL pointer, which can cause a kernel crash.

4

What is the relevant mitigation if the fix cannot be applied immediately?

Avoid the sequence that follows a failed coretemp initialization with CPU offlining or coretemp module unloading. The supplied data does not provide a configuration-based workaround that prevents the allocation failure itself.

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