KernelScan.io

HIGH

power PowerSupply UAF

CVE-2026-45946

CVSS 7.0 / 10.0 KernelScan AI

CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H

01

In the Linux kernel, the following vulnerability has been resolved: power: supply: ab8500: Fix use-after-free in power_supply_changed() Using the `devm_` variant for requesting IRQ _before_ the `devm_` variant for allocating/registering the `power_supply` handle, means that the `power_supply` handle will be deallocated/unregistered _before_ the interrupt handler (since `devm_` naturally deallocates in reverse allocation order). This means that during removal, there is a race condition where an interrupt can fire just _after_ the `power_supply` handle has been freed, *but* just _before_ the corresponding unregistration of the IRQ handler has run. This will lead to the IRQ handler calling `power_supply_changed()` with a freed `power_supply` handle. Which usually crashes the system or otherwise silently corrupts the memory... Note that there is a similar situation which can also happen during `probe()`; the possibility of an interrupt firing _before_ registering the `power_supply` handle. This would then lead to the nasty situation of using the `power_supply` handle *uninitialized* in `power_supply_changed()`. Commit 1c1f13a006ed ("power: supply: ab8500: Move to componentized binding") introduced this issue during a refactorization. Fix this racy use-after-free by making sure the IRQ is requested _after_ the registration of the `power_supply` handle.

02

Engine v0.2.0

Risk summary

Local attackers with low privileges can trigger a use-after-free vulnerability in the AB8500 power supply driver during device removal or probe. This can lead to kernel crashes, memory corruption, or potential privilege escalation through exploitation of the freed power_supply handle.

Affecteddrivers/power/supply/ab8500_charger.c (power supply subsystem)

Vulnerability analysis

The vulnerability stems from incorrect ordering of devm_ resource allocation in the AB8500 charger driver. The original code requested IRQs before registering the power_supply handle, but devm_ cleanup happens in reverse order, causing the power_supply to be freed before the IRQ handler is unregistered. This creates a race window where interrupts can fire after the power_supply is freed but before IRQ cleanup, leading to use-after-free when the handler calls power_supply_changed() with the freed handle. During probe, a similar issue can cause use of an uninitialized power_supply handle. The fix reorders the code to request IRQs after power_supply registration, ensuring proper cleanup order and eliminating the race window.

03

BranchFixed inPatch commit
5.145.1443cbb78ee047
5.155.15.202551672981fe2
6.16.1.165f50433f2603d
6.126.12.75709db4b476e2
6.186.18.1446dbda27b028
6.196.19.4c4af8a98bb52
6.66.6.128847eeb6c0efc
mainline7.0