CVE-2026-139656

leds: st1202: Take a reference on the LED firmware node

Published Nov 30, 2026 CVSS 3.1 · 4.1 Medium EPSS < 1% KEV · Not listed
Description
In the Linux kernel, the following vulnerability has been resolved:

leds: st1202: Take a reference on the LED firmware node

st1202_dt_init() stores each LED's firmware node while walking the
device tree with for_each_available_child_of_node_scoped(), which drops
its reference to the node at the end of every iteration. The LED class
stores the pointer with device_set_node() and does not take a reference
of its own, so nothing keeps the node alive for as long as the LED
device uses it. That has been the case since the driver was added, when
the LED class devices were registered inside that same loop.

Commit c72e455b89f2 ("leds: leds-st1202: Fix NULL pointer access on race
condition") moved the registration into a separate loop in
st1202_probe(), which also leaves the stored pointer unreferenced
between the two loops.

With CONFIG_OF_DYNAMIC the node can be freed while it is still in use,
leaving led->fwnode and the LED device's firmware node dangling.

Take a reference when the node is stored and release it through a devm
action. The action is registered before the LED class devices are, so it
runs after they have been unregistered.

Analysis

AI-generated

Technical impact

The Linux kernel driver for st1202 LEDs stores a hardware firmware node pointer while iterating over device tree child nodes but fails to hold a reference to that node. When the dynamic OF subsystem frees the node, the pointer held by the LED class becomes dangling, allowing a use‑after‑free that can corrupt kernel memory and result in a crash.

Affected Systems

The issue appears in the Linux kernel whenever the st1202 LED driver is compiled and CONFIG_OF_DYNAMIC is enabled. It affects all distributions using the driver with this configuration.

Risk and Exploitability

Because the exploit requires the node to be freed while the driver is still using it, the attack vector is likely local, such as an attacker with the ability to trigger the driver’s initialization path. No EPSS score is available, and the vulnerability is not listed in KEV. The CVSS score is 4.1, indicating moderate severity. The flaw could lead to a denial‑of‑service or potential privilege escalation if an attacker can cause the kernel to crash.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Apply a kernel update that contains the reference‑counting fix for st1202.
  • If the admin cannot immediately update, disable CONFIG_OF_DYNAMIC in the kernel configuration to prevent node freeing while in use.
  • Reboot the system after the update or configuration change to ensure the driver is re‑initialized with protected nodes.

Generated by OpenCVE AI on December 1, 2026 at 13:38 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Linux linux
Vendors & Products Linux linux
Type Values Removed Values Added
Weaknesses CWE-416
Type Values Removed Values Added
Weaknesses CWE-825
References
Metrics threat_severity

None

cvssV3_1

{'score': 4.1, 'vector': 'CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:N/I:N/A:H'}

threat_severity

Moderate

Type Values Removed Values Added
Weaknesses CWE-416
Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: leds: st1202: Take a reference on the LED firmware node st1202_dt_init() stores each LED's firmware node while walking the device tree with for_each_available_child_of_node_scoped(), which drops its reference to the node at the end of every iteration. The LED class stores the pointer with device_set_node() and does not take a reference of its own, so nothing keeps the node alive for as long as the LED device uses it. That has been the case since the driver was added, when the LED class devices were registered inside that same loop. Commit c72e455b89f2 ("leds: leds-st1202: Fix NULL pointer access on race condition") moved the registration into a separate loop in st1202_probe(), which also leaves the stored pointer unreferenced between the two loops. With CONFIG_OF_DYNAMIC the node can be freed while it is still in use, leaving led->fwnode and the LED device's firmware node dangling. Take a reference when the node is stored and release it through a devm action. The action is registered before the LED class devices are, so it runs after they have been unregistered.
Title leds: st1202: Take a reference on the LED firmware node
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References
Weaknesses
  • CWE-825

    Expired Pointer Dereference

Sources

Status
PUBLISHED
Assigner
Linux
Published
Updated
Nov 30, 2026, 1:36 PM
Reserved
Nov 30, 2026, 1:22 PM
Status
Received
Published
Nov 30, 2026, 2:19 PM
Modified
Nov 30, 2026, 2:19 PM
Severity
Moderate
Public date
Nov 30, 2026, 1:36 PM