mm/page_counter: avoid integer overflow in effective_protection()

Summary

CVECVE-2026-138864
StatePUBLISHED
AssignerLinux
Source PriorityCVE Program / NVD first with legacy fallback
Published2026-11-30 14:17:42 UTC
Updated2026-11-30 14:17:42 UTC
DescriptionIn the Linux kernel, the following vulnerability has been resolved: mm/page_counter: avoid integer overflow in effective_protection() Patch series "mm/mglru: fix ineffective memory protection for non-kswapd reclaim", v4. For MGLRU, memory.min/low is not honored during non-kswapd global reclaim (global direct reclaim and root-level memory.reclaim), because these paths shrink memcgs using stale protection (emin/elow). Patch 2 is the actual fix. Patch 1 is a prerequisite: an integer overflow in effective_protection(), spotted by the sashiko review tool, which patch 2's new caller would also be exposed to. This patch (of 2): effective_protection() scales a parent's protection by a ratio of page counts, e.g. for recursive protection: (parent_effective - siblings_protected) * (usage - protected) / (parent_usage - siblings_protected) The multiply is done at unsigned long width before dividing. On systems with >= 16TB RAM the product can exceed 2^64 and wrap, giving a bogus protection value and silently breaking memory.min/low enforcement. Use mul_u64_u64_div_u64() to multiply in a 128-bit intermediate. Because usage and parent_usage are not read atomically (a child is charged before its parent), usage - protected can briefly exceed the divisor, making the quotient overflow 64 bits and trap (#DE on x86). Cap it so the ratio stays <= 1. Reported by the sashiko review tool [1].

Vendor Declared Affected Products

SourceVendorProductVersionPlatforms
CNA Linux Linux affected bc50bcc6e00b8509e64875c674f4573e8b4df1e8 c380274c205add299b48135ef6cd11e67aac29b2 git Not specified
CNA Linux Linux affected bc50bcc6e00b8509e64875c674f4573e8b4df1e8 d8957533806e9f291e8e65ee2bb12163ce5ecebc git Not specified
CNA Linux Linux affected bc50bcc6e00b8509e64875c674f4573e8b4df1e8 2748bfeb1c12aa99670c08a34f5ff07ba6945c89 git Not specified
CNA Linux Linux affected bc50bcc6e00b8509e64875c674f4573e8b4df1e8 7809ce47b05671e1fa6d74bead892d6ad6c1403b git Not specified
CNA Linux Linux affected 5.7 Not specified
CNA Linux Linux unaffected 5.7 semver Not specified
CNA Linux Linux unaffected 6.12.118 6.12.* semver Not specified
CNA Linux Linux unaffected 6.18.64 6.18.* semver Not specified
CNA Linux Linux unaffected 7.3.4 7.3.* semver Not specified
CNA Linux Linux unaffected 7.4-rc1 * original_commit_for_fix Not specified

References

ReferenceSourceLinkTags
git.kernel.org/stable/c/c380274c205add299b48135ef6cd11e67aac29b2 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org
git.kernel.org/stable/c/2748bfeb1c12aa99670c08a34f5ff07ba6945c89 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org
git.kernel.org/stable/c/7809ce47b05671e1fa6d74bead892d6ad6c1403b 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org
git.kernel.org/stable/c/d8957533806e9f291e8e65ee2bb12163ce5ecebc 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

© CVE.report 2026

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report