Skip to main content
Vulnerability Database/CVE-2026-93217

CVE-2026-93217: Linux Kernel madvise Race Condition Vulnerability

CVE-2026-93217 is a race condition flaw in the Linux kernel's madvise function that causes system panics when device-private PMDs are encountered. This article covers the technical details, security impact, and mitigation strategies.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-93217 Overview

CVE-2026-93217 is a Linux kernel vulnerability in the memory management subsystem. The flaw resides in madvise_cold_or_pageout_pte_range() within mm/madvise.c. The function fails to handle device-private page middle directory (PMD) entries correctly during MADV_COLD and MADV_PAGEOUT operations. A VM_BUG_ON() assertion triggers when a Heterogeneous Memory Management (HMM) GPU driver races with madvise operations, causing a kernel panic.

Critical Impact

A race between HMM-based GPU drivers and madvise(MADV_COLD) or MADV_PAGEOUT calls can trip a kernel VM_BUG_ON() assertion, resulting in a denial-of-service panic on systems using device-private memory.

Affected Products

  • Linux kernel versions containing the vulnerable madvise_cold_or_pageout_pte_range() logic
  • Systems with HMM-based GPU drivers using device-private memory
  • Kernel builds with CONFIG_ARCH_SUPPORTS_PMD_SOFTLEAF enabled

Discovery Timeline

  • 2026-09-24 - CVE-2026-93217 published to the National Vulnerability Database
  • 2026-09-24 - Last updated in NVD database

Technical Details for CVE-2026-93217

Vulnerability Analysis

The vulnerability lives in the memory advise path. When user space calls madvise() with MADV_COLD or MADV_PAGEOUT, the kernel invokes madvise_cold_or_pageout_pte_range(). The function acquires pmd_trans_huge_lock(), whose pmd_is_huge() check returns true for a device-private PMD.

The subsequent !pmd_present() branch contains a VM_BUG_ON() that asserts migration is the only permitted non-present case. A device-private PMD violates this assertion. The kernel then panics on systems compiled with assertions enabled.

The race window opens when pmd_trans_huge(*pmd) reads true, then migrate_vma_pages() flips the PMD to a device-private entry before the PMD lock is acquired. This classifies as a race condition and kernel vulnerability affecting denial of service.

Root Cause

The root cause is incomplete handling of PMD state transitions in the madvise walk. The code assumes migration entries are the only non-present huge PMD state. HMM device-private entries introduce a third state that the assertion does not account for. The fix skips device-private PMDs in the non-present branch and downgrades VM_BUG_ON() to VM_WARN_ON_ONCE().

Attack Vector

An unprivileged local process can trigger the condition by issuing madvise(MADV_COLD) or madvise(MADV_PAGEOUT) against memory regions managed by an HMM GPU driver. The attack requires concurrent GPU workload activity to drive migrate_vma_pages() and win the race against the madvise walker. Successful exploitation panics the kernel.

The vulnerability requires local access and a system with an HMM-capable GPU driver. No verified public exploit is available. See the kernel commit log for technical details at commit 5c0d7b658cda and commit d4b76d0b03cb.

Detection Methods for CVE-2026-93217

Indicators of Compromise

  • Unexpected kernel panics referencing madvise_cold_or_pageout_pte_range in the stack trace
  • VM_BUG_ON messages citing pmd_present assertions in mm/madvise.c
  • System crashes correlated with GPU workload activity using HMM device-private memory

Detection Strategies

  • Monitor kernel ring buffer (dmesg) and /var/log/kern.log for VM_BUG_ON or oops traces originating from the madvise code path
  • Correlate crash dumps with concurrent calls to madvise() with MADV_COLD or MADV_PAGEOUT advice codes
  • Track GPU driver module loads alongside memory management warnings to identify at-risk hosts

Monitoring Recommendations

  • Enable kdump to capture crash dumps for forensic analysis of panic traces
  • Audit which workloads invoke madvise() with page-out advice on hosts running HMM-capable GPUs
  • Centralize kernel log collection to detect repeated warnings that may precede exploitation attempts

How to Mitigate CVE-2026-93217

Immediate Actions Required

  • Apply the upstream kernel patches referenced in the stable tree commits as soon as distribution packages are available
  • Inventory systems running HMM-based GPU drivers and prioritize those for patching
  • Restrict untrusted local workloads on hosts that expose GPU device-private memory to user space

Patch Information

The fix is published in the Linux stable tree. The patch modifies madvise_cold_or_pageout_pte_range() to skip device-private PMDs in the non-present branch, proceeds to huge_unlock before calling pmd_folio(), and downgrades the fatal VM_BUG_ON() to a non-fatal VM_WARN_ON_ONCE(). Reference the kernel commits 5c0d7b658cda and d4b76d0b03cb.

Workarounds

  • Disable or unload HMM-based GPU drivers on exposed systems where feasible until patches are deployed
  • Limit local user access on hosts that cannot be patched immediately
  • Avoid running workloads that combine GPU device-private memory with aggressive MADV_PAGEOUT usage
bash
# Verify the running kernel version and check for the fix
uname -r

# Inspect kernel logs for madvise-related warnings or panics
dmesg | grep -iE 'madvise|VM_BUG_ON|pmd_present'

# Identify loaded HMM-capable GPU drivers
lsmod | grep -iE 'nouveau|amdgpu|nvidia'

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.