Linux Kernel Amlogic RTC Driver Double Free Vulnerability

Vulnerability

A double free vulnerability has been identified in the Amlogic RTC driver of the Linux kernel. This issue arises from improper management of a clock resource obtained through the devm_clk_get_enabled() function. The devm framework is designed to automatically handle the lifecycle of such resources, freeing them when the driver is detached. However, the driver currently includes manual calls to clk_disable_unprepare() in both the error handling and removal functions, leading to a double free situation. The vulnerability affects the Linux kernel stable tree.

Impact

Exploitation of this vulnerability could lead to a double free condition, which may be exploited to cause memory corruption.

Reproduction

The vulnerability can be reproduced by loading the Amlogic RTC driver in a scenario where an error occurs during the probe process. The driver will incorrectly free the same clock resource twice, creating a double free vulnerability. This can also be observed when the driver is removed, as the same erroneous clock handling occurs.

Remediation

The vulnerability has been addressed by removing the redundant clk_disable_unprepare() calls from the driver's probe error path and the aml_rtc_remove() function. Users should update to the latest version of the Linux kernel where this fix has been applied.

Added: Jan 5, 2026, 10:34 AM
Updated: Jan 5, 2026, 10:34 AM

Vulnerability Rating

Custom Algorithm
spread
9.0
impact
2.5
exploitability
4.3
remediation
7.7
relevance
1.8
threat
4.8
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.