In the Linux kernel, the following vulnerability has been resolved: sparc: fix accurate exception reporting in copy_{from_to}_user for UltraSPARC… (CVE-2025-40124)
A vulnerability in the Linux kernel related to the sparc architecture has been resolved. The issue involved inaccurate exception reporting in the copy_from_user and copy_to_user functions for UltraSPARC III processors. Specifically, a BUG_ON in ext4 code with large folios was triggered due to copy_from_user returning values larger than the size to be copied, causing __copy_from_iter to return impossible values. The root cause was improper masking of register %o2 during the bulk copy loop in exception handlers. This flaw affected the correctness of return values in fault cases but did not change memcpy behavior.
AI Analysis
Technical Summary
CVE-2025-40124 addresses a vulnerability in the Linux kernel's sparc architecture implementation where exception handlers in copy_from_user and copy_to_user functions incorrectly handled register masking. This caused these functions to return invalid byte counts when exceptions occurred during user-space memory references, leading to a BUG_ON in ext4 code with large folios enabled. The fix corrects the timing of masking register %o2 during the bulk copy loop, ensuring accurate return values and exception reporting. The vulnerability impacts UltraSPARC III processors and does not affect memcpy behavior.
Potential Impact
The vulnerability could cause kernel code relying on copy_from_user or copy_to_user to receive incorrect byte counts, potentially leading to kernel BUGs or crashes, particularly in ext4 filesystem operations with large folios enabled. This impacts confidentiality, integrity, and availability of the system due to possible kernel panics or denial of service. There is no indication of remote exploitation or privilege escalation from the provided data.
Mitigation Recommendations
A fix for this vulnerability has been implemented in the Linux kernel source code. Users and administrators should apply the official kernel updates that include this patch to resolve the issue. Since this is a kernel-level fix, upgrading to the patched kernel version is the recommended remediation. Patch status is not explicitly confirmed in the provided data; therefore, check the official Linux kernel advisories or vendor updates for the exact fixed versions and apply them accordingly.
In the Linux kernel, the following vulnerability has been resolved: sparc: fix accurate exception reporting in copy_{from_to}_user for UltraSPARC… (CVE-2025-40124)
Description
A vulnerability in the Linux kernel related to the sparc architecture has been resolved. The issue involved inaccurate exception reporting in the copy_from_user and copy_to_user functions for UltraSPARC III processors. Specifically, a BUG_ON in ext4 code with large folios was triggered due to copy_from_user returning values larger than the size to be copied, causing __copy_from_iter to return impossible values. The root cause was improper masking of register %o2 during the bulk copy loop in exception handlers. This flaw affected the correctness of return values in fault cases but did not change memcpy behavior.
CVSS v3.1
Score 7.8high
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2025-40124 addresses a vulnerability in the Linux kernel's sparc architecture implementation where exception handlers in copy_from_user and copy_to_user functions incorrectly handled register masking. This caused these functions to return invalid byte counts when exceptions occurred during user-space memory references, leading to a BUG_ON in ext4 code with large folios enabled. The fix corrects the timing of masking register %o2 during the bulk copy loop, ensuring accurate return values and exception reporting. The vulnerability impacts UltraSPARC III processors and does not affect memcpy behavior.
Potential Impact
The vulnerability could cause kernel code relying on copy_from_user or copy_to_user to receive incorrect byte counts, potentially leading to kernel BUGs or crashes, particularly in ext4 filesystem operations with large folios enabled. This impacts confidentiality, integrity, and availability of the system due to possible kernel panics or denial of service. There is no indication of remote exploitation or privilege escalation from the provided data.
Mitigation Recommendations
A fix for this vulnerability has been implemented in the Linux kernel source code. Users and administrators should apply the official kernel updates that include this patch to resolve the issue. Since this is a kernel-level fix, upgrading to the patched kernel version is the recommended remediation. Patch status is not explicitly confirmed in the provided data; therefore, check the official Linux kernel advisories or vendor updates for the exact fixed versions and apply them accordingly.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-v3c5-2xf8-7jwx
- Osv Schema Version
- 1.4.0
- Aliases
- ["CVE-2025-40124"]
- Database Specific Severity
- HIGH
- Cvss Version
- 3.1
Threat ID: 6a6b72d69c2644c7f847a8bf
Added to database: 07/30/2026, 15:50:46 UTC
Last enriched: 07/30/2026, 16:52:38 UTC
Last updated: 09/10/2026, 19:38:45 UTC
Views: 11
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.