CVE-2026-138969: MIPS: mm: do not write a huge TLB entry when the probe misses
In the Linux kernel, the following vulnerability has been resolved:
MIPS: mm: do not write a huge TLB entry when the probe misses
updatetlb() probes for the 8K pair at the address it is given and, for a huge pmd, writes the huge entry with tlbwi at the probed index or with tlbwr when the probe misses. That works only if the caller passes the faulting address, so that the probe finds the 4K entry the refill handler loaded for the faulting page and the huge entry replaces it.
updatemmucachepmd() is not called that way. dosetpmd() has always passed the huge-aligned address, and since commit ebcfc63d6bca ("mm: abstract THP allocation") the anonymous THP fault path does too (mapanonfoliopmd()). The probe then misses the stale 4K entry, which sits at the faulting page somewhere else in the 2 MB range, tlbwr adds a huge entry next to it, and the TLB holds two entries matching the faulting address. Octeon raises "Machine Check exception - caused by multiple matching entries in the TLB" on the next refill of that page; a process on a CN63XX board died this way within a second of start, on the first anonymous THP of its bss.
Skip the write when the probe misses. The refill and TLBL/TLBS handlers probe the faulting address themselves and rewrite the stale entry with the huge one (they also set the software young bit), so the entry is installed on the next access at the cost of one exception.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 5.10.275 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 5.15.226 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 6.1.193 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 6.6.163 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 6.12.117 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 6.18.63 - Upgrade
Upgrade
linux/Kernelto a version that resolves this vulnerability.Fixed in 7.3.4 - Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 6.12.117-1 - Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 7.3.4-1 - Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 6.12.117-1Fixed in 7.3.4-1 - Compensating control
In the Linux kernel MIPS TLB update path, skip the TLB write when the probe misses.
Event History
Frequently Asked Questions
Which systems are most likely to be exposed?
The issue affects Linux kernel systems on MIPS that use huge PMD mappings. It was observed on an Octeon CN63XX board when the process encountered its first anonymous transparent huge page.
What condition triggers the failure?
A huge PMD update can probe using a huge-page-aligned address while a stale 4K TLB entry exists for the faulting page elsewhere in the same 2 MB range. On a probe miss, writing a huge entry can leave both entries matching the faulting address.
How can administrators recognize that the system is affected?
Affected systems may report a Machine Check exception caused by multiple matching TLB entries. A process can terminate on the next refill of the affected page, potentially shortly after startup when anonymous THP is used.
What does the fix do?
The fix skips writing the huge TLB entry when the probe misses. This avoids adding a huge entry alongside the stale 4K entry that can produce duplicate TLB matches.