Critical SME Trap Handling Vulnerability in Linux Kernel
Summary
CVE-2025-38170: In the Linux kernel, the following vulnerability has been resolved: arm64/fpsimd: Discard stale CPU state when handling SME traps The logic for handling SME traps manipulates saved FPSIMD/SVE/SME state incorrectly, and a... Affects linux versions < 6.1.147-1. Fixed in 6.1.147-1. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
The Linux kernel is the core component of many operating systems, responsible for managing hardware resources and providing essential services to software applications. It supports a wide range of hardware architectures and is known for its stability and performance. However, vulnerabilities can arise, such as the one related to the handling of Scalable Matrix Extensions (SME) traps, which can lead to improper CPU state management and potential system instability.
Vulnerability Detail
In the Linux kernel, a vulnerability has been identified in the handling of SME traps on arm64 architecture. The issue arises from incorrect manipulation of saved FPSIMD/SVE/SME state during the handling of these traps, which can lead to a race condition with preemption. This race condition can result in a task having TIF_SME set while TIF_FOREIGN_FPSTATE is clear, even when the live CPU state is stale. Consequently, this can trigger warnings during SME trap handling, indicating that userspace should not generate any traps when TIF_SME is set. The vulnerability is similar to a previously fixed issue related to SVE traps, highlighting the need for careful state management in concurrent environments.
How To Fix
Minimum fixed version
6.1.147-1
This is the first release that contains the fix.
sudo apt-get install --only-upgrade linux
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
As a temporary workaround, users can disable SME traps if they are not required for their applications. This can be done by modifying the kernel boot parameters to prevent SME from being enabled, although this may not be suitable for all users depending on their specific use cases.
Conclusion
The vulnerability in the Linux kernel related to SME trap handling poses significant risks due to improper CPU state management. It is crucial for users to update their systems to the latest patched versions of the kernel to ensure stability and security. Temporary workarounds can be employed, but they should not replace proper updates.
See every vulnerability recorded for linux →
FAQ
The vulnerability can lead to improper CPU state management, which may cause system instability and unexpected behavior in applications relying on SME.
You can use tools like Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without any signup.
Yes, a patch has been released in newer versions of the Linux kernel. It is advisable to update to the latest version to mitigate the risk.
If an immediate update is not possible, consider disabling SME traps as a temporary workaround until you can apply the patch.
Detailed information can be found in the CVE database and through the Linux kernel mailing lists, where discussions about vulnerabilities are held.
Related vulnerabilities
Recent vulnerabilities recorded for linux.