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

rtc: ac100: Fix clock provider use-after-free on probe failure

ac100_rtc_register_clks() registers the RTC-32k clock with
clk_hw_register_fixed_rate() and the clock provider with
of_clk_add_hw_provider(). Neither is device managed, and both are
released only from ac100_rtc_remove(). The driver core does not call
remove() when probe() fails: really_probe() reaches probe_failed below
the device_remove() call and goes straight to releasing the device's
managed resources.

ac100_rtc_probe() ends with

return devm_rtc_register_device(chip->rtc);

so if that fails after the clocks have been registered, the provider is
left on the global of_clk_providers list holding chip->clk_data, which
was allocated with devm_kzalloc() and is freed while probe() unwinds. A
later lookup on this device tree node then reads freed memory in
of_clk_hw_onecell_get(). Consumers that do exactly that exist in tree:
the wifi power sequence nodes on sun8i-a83t-bananapi-m3 and
sun8i-a83t-cubietruck-plus take <&ac100_rtc 1>, and the sun9i-a80 boards
route osc32k through <&ac100_rtc 0>. The window is narrow, as
devm_rtc_register_device() can only fail with -ENOMEM here, but the
provider is left dangling whenever it does.

The RTC-32k clock is leaked on the same path. Since clk_core_lookup()
searches a global list that is not scoped per device, __clk_register()
rejects the duplicate name with -EEXIST, so the leak also makes a later
probe of the same device fail.

The error path that returns -EINVAL when the ADDA 4M parent clock cannot
be found leaks the RTC-32k clock in the same way. No provider has been
registered at that point, so that one is a leak rather than a
use-after-free.

Register both with devm_clk_hw_register_fixed_rate() and
devm_of_clk_add_hw_provider() so that they are released whenever the
device goes away, on a failed probe as well as on unbind. Devres
releases in reverse order of acquisition, so the provider is removed
before chip->clk_data is freed, and the clkout children are now
unregistered before their parent rather than after it.
ac100_rtc_unregister_clks() and the remove callback then have nothing
left to do and are removed.
Published: 2026-10-18
Score: 4.7 Medium
EPSS: < 1% Very Low
KEV: No
Impact: Use‑After‑Free in the Linux kernel RTC ac100 driver
Action: Apply Patch
AI Analysis

Impact

The ac100 RTC driver registers a clock provider and fixed‑rate clock without device‑managed ownership. If probe fails after these registrations—either due to devm_rtc_register_device returning –ENOMEM or an earlier error that skips provider registration—the provider remains in the global clock provider list while the memory owned by devm_kzalloc is freed. A subsequent call to of_clk_hw_onecell_get for the same device‑tree node enumerates the dangling provider, resulting in a read of freed memory. This use‑after‑free can corrupt kernel data structures and lead to a kernel panic or, if the attacker can influence the data read, arbitrary code execution. The weakness corresponds to improper resource cleanup during error handling (CWE‑416).

Affected Systems

Any Linux kernel that includes the ac100 RTC driver in its source tree and has not applied the patch that moves the clock registrations into devres is vulnerable. The vulnerability exists in the driver code regardless of distribution or kernel version prior to the fix; therefore all unpatched installations that load the ac100 RTC module are affected.

Risk and Exploitability

The CVSS score of 4.7 indicates moderate impact, and the EPSS score of <1% suggests that exploitation is unlikely in the wild. However, based on the description, the likely attack vector is a local privileged process that can trigger the driver to probe a malformed or missing device‑tree node, causing probe failure. After the failure, any subsequent lookup of the provider—such as a power‑sequence node on a Sun4I SoC—is needed to reach the use‑after‑free. The vulnerability is not listed in the CISA KEV catalog, so no widely available exploits are known at this time.

Generated by OpenCVE AI on October 20, 2026 at 18:58 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the kernel to a version that includes the ac100 driver patch, which registers clocks via devres and guarantees cleanup on probe failure.
  • Reboot the system after the kernel update so that any stale clock provider entries are cleared before the new driver loads.
  • If a patch is not yet available, prevent the use of the ac100 RTC provider by disabling the driver module or removing any device‑tree nodes that reference the provider, thereby eliminating the path that could trigger the use‑after‑free.

Generated by OpenCVE AI on October 20, 2026 at 18:58 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Debian DLA Debian DLA DLA-4850-1 linux-6.12 security update
History

Tue, 20 Oct 2026 12:45:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

cvssV3_1

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

threat_severity

Moderate


Sun, 18 Oct 2026 20:45:00 +0000

Type Values Removed Values Added
Weaknesses CWE-416

Sun, 18 Oct 2026 16:00:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: rtc: ac100: Fix clock provider use-after-free on probe failure ac100_rtc_register_clks() registers the RTC-32k clock with clk_hw_register_fixed_rate() and the clock provider with of_clk_add_hw_provider(). Neither is device managed, and both are released only from ac100_rtc_remove(). The driver core does not call remove() when probe() fails: really_probe() reaches probe_failed below the device_remove() call and goes straight to releasing the device's managed resources. ac100_rtc_probe() ends with return devm_rtc_register_device(chip->rtc); so if that fails after the clocks have been registered, the provider is left on the global of_clk_providers list holding chip->clk_data, which was allocated with devm_kzalloc() and is freed while probe() unwinds. A later lookup on this device tree node then reads freed memory in of_clk_hw_onecell_get(). Consumers that do exactly that exist in tree: the wifi power sequence nodes on sun8i-a83t-bananapi-m3 and sun8i-a83t-cubietruck-plus take <&ac100_rtc 1>, and the sun9i-a80 boards route osc32k through <&ac100_rtc 0>. The window is narrow, as devm_rtc_register_device() can only fail with -ENOMEM here, but the provider is left dangling whenever it does. The RTC-32k clock is leaked on the same path. Since clk_core_lookup() searches a global list that is not scoped per device, __clk_register() rejects the duplicate name with -EEXIST, so the leak also makes a later probe of the same device fail. The error path that returns -EINVAL when the ADDA 4M parent clock cannot be found leaks the RTC-32k clock in the same way. No provider has been registered at that point, so that one is a leak rather than a use-after-free. Register both with devm_clk_hw_register_fixed_rate() and devm_of_clk_add_hw_provider() so that they are released whenever the device goes away, on a failed probe as well as on unbind. Devres releases in reverse order of acquisition, so the provider is removed before chip->clk_data is freed, and the clkout children are now unregistered before their parent rather than after it. ac100_rtc_unregister_clks() and the remove callback then have nothing left to do and are removed.
Title rtc: ac100: Fix clock provider use-after-free on probe failure
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References

Subscriptions

Linux Linux Kernel
cve-icon MITRE

Status: PUBLISHED

Assigner: Linux

Published:

Updated: 2026-10-19T09:26:19.030Z

Reserved: 2026-09-25T10:25:14.372Z

Link: CVE-2026-98826

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-18T16:17:36.823

Modified: 2026-10-19T10:19:46.643

Link: CVE-2026-98826

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-10-18T15:49:19Z

Links: CVE-2026-98826 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-20T19:00:16Z

Weaknesses