CVE-2026-138895
publishedmm: hugetlb: drop refcount before freeing on memcg charge failure
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| Linux | — | Linux991135774c0e05a4734e6d32aa03b00355e4cac9 to < eeb9425606f386f726b47ee323687ee02c7b34f8 · 991135774c0e05a4734e6d32aa03b00355e4cac9 to < 3f87063217efc3b0198e49ec1a9b262ff81ac406 · 991135774c0e05a4734e6d32aa03b00355e4cac9 to < e95d29c5df84f19881cd30b491fc81aa98f44b45 · Other versions: unaffected | Affected | Not stated | Linux |
| Linux | — | Linux6.14 (affected) · 0 to < 6.14 (unaffected · semver) · 6.18.64 through 6.18.* (unaffected · semver) · 7.3.4 through 7.3.* (unaffected · semver) · 7.4-rc1 and later (unaffected · original_commit_for_fix) · Other versions: affected | Version-specific | Not stated | Linux |
Description
In the Linux kernel, the following vulnerability has been resolved: mm: hugetlb: drop refcount before freeing on memcg charge failure When mem_cgroup_charge_hugetlb(folio, gfp) returns -ENOMEM, the folio has its refcount set to 1 via folio_ref_unfreeze(folio, 1). The error path calls free_huge_folio(folio) directly, which expects a refcount of 0. Hence, VM_BUG_ON_FOLIO(folio_ref_count(folio), folio) is triggered. Even with CONFIG_DEBUG_VM disabled, returning a folio with refcount 1 to the freelist can corrupt allocator state later. Use folio_put(folio) instead of free_huge_folio(folio) to properly drop the reference before freeing it.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
No normalized assessments.
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| Linux | Linux | 991135774c0e05a4734e6d32aa03b00355e4cac9 to < eeb9425606f386f726b47ee323687ee02c7b34f8 (affected · git)991135774c0e05a4734e6d32aa03b00355e4cac9 to < 3f87063217efc3b0198e49ec1a9b262ff81ac406 (affected · git)991135774c0e05a4734e6d32aa03b00355e4cac9 to < e95d29c5df84f19881cd30b491fc81aa98f44b45 (affected · git)Default: unaffected | Linux · cna |
| Linux | Linux | 6.14 (affected)0 to < 6.14 (unaffected · semver)6.18.64 through 6.18.* (unaffected · semver)7.3.4 through 7.3.* (unaffected · semver)7.4-rc1 and later (unaffected · original_commit_for_fix)Default: affected | Linux · cna |
Weaknesses
0No weakness assertions.
References
3Provider assertions
1Linux · cna
mm: hugetlb: drop refcount before freeing on memcg charge failure
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 069dfcd5823fe5e365a9879eee6b15677b4430413871478a62aa0d572a14a2f2
- Ingested
- 30 Nov 2026, 13:30:07 UTC
- Source record
- Official CVE record