CVE-2025-38421 platform/x86/amd: pmf: Use device managed allocations
A double free vulnerability in the AMD PMF kernel driver can cause system crashes or potential code execution during module unloading.
- 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-2025-38421?
CVE-2025-38421 is a high-severity use after free vulnerability in Linux kernel, published on 25 Jul 2025. 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:
platform/x86/amd: pmf: Use device managed allocations
If setting up smart PC fails for any reason then this can lead to a double free when unloading amd-pmf. This is because dev->buf was freed but never set to NULL and is again freed in amd_pmf_remove().
To avoid subtle allocation bugs in failures leading to a double free change all allocations into device managed allocations.
Weakness: CWE-415
Which versions are affected by CVE-2025-38421?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2025-38421?
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-2025-38421 being exploited?
There is no known exploitation of CVE-2025-38421 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as BELL-CVE-2025-38421, DEBIAN-CVE-2025-38421, GHSA-mxc4-v7c2-8m69, ROOT-OS-DEBIAN-13-CVE-2025-38421, ROOT-OS-UBUNTU-2404-CVE-2025-38421, UBUNTU-CVE-2025-38421.