mm/shmem: hold off eviction in shmem_writeout()
Severity and exploitation
KEV coverage does not rule out exploitation.
Severity
unknownCVSS measures technical severity, not the likelihood of an attack.
Known exploitation
Not listed in the checked CISA KEV catalog
Absence from CISA KEV does not rule out attacks.
Public exploit
Not established by this record
Missing evidence does not mean no public exploit exists.
Remediation
Fix status not established
No structured fix or guidance is available here. Check the latest publisher advisory.
What this means
A vulnerability in Linux kernel versions 6.17 and earlier, and git versions before d64fd1229fb1437d7c62c49eba82691bfd65d541, allows for a use-after-free weakness. The impact is uncertain.
Summarized by @cf/meta/llama-3.3-70b-instruct-fp8-fast. Verify details against the original sources.Attack conditions
No attack-condition excerpt has been identified here. Review the full source description and references for authentication, network access, and configuration requirements.
Review supporting sources →Affected versions
Check the exact model, release, and any platform requirements against your installation.
Linux · Linux
Linux
3 ranges
Linux · Linux
Linux
Compare with this publisher’s ranges. This does not inspect your installation.
affected
6344a6d9ce13ae29e3ddf280fd8a1109a77b9996 → before d64fd1229fb1437d7c62c49eba82691bfd65d541
git versions
6344a6d9ce13ae29e3ddf280fd8a1109a77b9996 → before f53ee5a65460010cabd75895d83258d90923ca7a
git versions
6344a6d9ce13ae29e3ddf280fd8a1109a77b9996 → before 8f59173b5ca358bf4d1017b44da3cbe6faa80daf
git versions
Other versions: unaffected
Linux · Linux
Linux
5 ranges
Linux · Linux
Linux
Compare with this publisher’s ranges. This does not inspect your installation.
affected
6.17
unaffected
0 → before 6.17
semver versions
6.18.65 → through 6.18.*
semver versions
7.3.6 → through 7.3.*
semver versions
7.4-rc2 → through *
original_commit_for_fix versions
Other versions: affected
What to do
Compare your installed product and version with the affected versions above. A matching product name alone does not confirm exposure.
No structured fix or remediation guidance is available here. Check the full source description and vendor’s latest advisory for a patch or workaround; do not assume another version is safe.
cve.new guidance unless attributed to a publisher. This page does not inspect your installation.
Public exploit evidence
No public exploit reference is identified in the imported evidence. This is not a claim that no exploit exists.
Original source description
Read the full publisher description
In the Linux kernel, the following vulnerability has been resolved:
mm/shmem: hold off eviction in shmem_writeout()
Once shmem_writeout() has moved the folio from the page cache to the swap cache, the folio lock no longer keeps the inode alive: truncation and eviction find a swap entry, free it and do not wait for anybody. That did not matter as long as swap_writeout() was the last thing the function did. But since it puts the folio back when swap_writeout() returns AOP_WRITEPAGE_ACTIVATE, it uses the mapping and the inode afterwards:
reclaim last close of an unlinked file shmem_writeout() shmem_delete_from_page_cache() swap_writeout() zswap_store() fails shmem_evict_inode() writeback is disabled shmem_truncate_range() return AOP_WRITEPAGE_ACTIVATE shmem_free_swap() destroy_inode() ... RCU grace period, freed shmem_add_to_page_cache(mapping) xas_lock_irq() <- use after free
swap_writeout() behaves that way if zswap is enabled, cannot take the folio and the memcg or one of its ancestors has memory.zswap.writeback set to 0.
shmem_unuse() already added infrastructure to deal with that. Reuse info->stop_eviction to protect the inode during writeout. Increment it before removing the folio from the page cache, and decrement it after swap_writeout() and any attempted reinsertion and inode accounting. In shmem_evict_inode(), wait for the counter to reach zero even if swapoff has already removed the inode from the swap list. Add some helpers to make the code easier to digest.
There is a known remaining issue with two swapoffs racing, and the empty list check not being able to detect that race. That will be addressed separately later.
Fix generated by an LLM and sent by Josef Bacik in private.
[ david: code cleanups; improve description ]
References
3 sourcesInside the record
Evidence available
Describes the evidence in this view, not whether the product is safe.
Original records
CVE-2026-139799View the latest unmodified CVE JSON from the official source. It may be newer than this imported page.
cve.new JSON →Environment requirements
These conditions apply together as specified by the publisher. A matching product name alone does not establish exposure.
Linux · platform conditions
Any condition may hold
Vulnerable product
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*From (inclusive): 6.17
Before: 6.18.65
Vulnerable product
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*From (inclusive): 6.17
Before: 7.3.6
Vulnerable product
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*From (inclusive): 6.17
Before: 7.4-rc2
Applicability preview
[
{
"nodes": [
{
"operator": "OR",
"negate": false,
"cpeMatch": [
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "6.17",
"versionEndExcluding": "6.18.65"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "6.17",
"versionEndExcluding": "7.3.6"
},
{
"vulnerable": true,
"criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
"versionStartIncluding": "6.17",
"versionEndExcluding": "7.4-rc2"
}
]
}
]
}
]Contributing organizations · 1
Assigning organization
Timeline
All times UTCAdvisory published
Publication date supplied by the source.
Last imported by cve.new
Latest catalog import, not the date we first saw this advisory.
What changed
Follow changesLarge field values are marked as truncated previews. Original source snapshots remain retained.
Related advisories
Recent advisories affecting the same package or the same recorded vendor and product. These are separate vulnerabilities, not additional evidence for this advisory.
KVM: nSVM: Check validity of vmcs01 save area copied from SMRAM on RSM
In the Linux kernel, the following vulnerability has been resolved:
No structured fix or guidance is available here. Check the latest publisher advisory.
Exploitation not established
9p/xen: drain response work after unbinding IRQ
In the Linux kernel, the following vulnerability has been resolved:
No structured fix or guidance is available here. Check the latest publisher advisory.
Exploitation not established
mm: do not unintentionally overwrite atomic VMA flags
In the Linux kernel, the following vulnerability has been resolved:
No structured fix or guidance is available here. Check the latest publisher advisory.
Exploitation not established
ocfs2/cluster: hold a reference on the heartbeat thread
In the Linux kernel, the following vulnerability has been resolved:
No structured fix or guidance is available here. Check the latest publisher advisory.
Exploitation not established
ocfs2/heartbeat: serialize concurrent writes to a region's dev attribute
In the Linux kernel, the following vulnerability has been resolved:
No structured fix or guidance is available here. Check the latest publisher advisory.
Exploitation not established
net: mana: Add support to process throttled EQEs
In the Linux kernel, the following vulnerability has been resolved:
No structured fix or guidance is available here. Check the latest publisher advisory.
Exploitation not established