CVE-2026-45879 power: supply: bq25980: Fix use-after-free in power_supply_changed()
A race condition in the bq25980 power supply driver allows a use-after-free, potentially causing system crashes or memory corruption.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2026-45879?
CVE-2026-45879 is a high-severity use after free vulnerability in Linux kernel, published on 27 May 2026. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
In the Linux kernel, the following vulnerability has been resolved:
power: supply: bq25980: 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()`.
Fix this racy use-after-free by making sure the IRQ is requested _after_ the registration of the `power_supply` handle.
Weakness: CWE-416
Which versions are affected by CVE-2026-45879?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2026-45879?
Apply the vendor's patch.
Upgrade to the fixed version. These bugs are found with fuzzing and sanitisers and avoided by memory-safe languages. More about Use after free.
Is CVE-2026-45879 being exploited?
There is no known exploitation of CVE-2026-45879 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as BELL-CVE-2026-45879, DEBIAN-CVE-2026-45879, GHSA-ww5g-f76r-4mww, ROOT-OS-DEBIAN-11-CVE-2026-45879, ROOT-OS-UBUNTU-2204-CVE-2026-45879, ROOT-OS-UBUNTU-2404-CVE-2026-45879 and 1 more.