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

CVE-2026-98178: Linux Kernel Privilege Escalation Vulnerability

CVE-2026-98178 is a privilege escalation vulnerability in the Linux kernel affecting the AMDGPU driver. The flaw allows potential unauthorized access through improper handling of KFD device initialization failures. This article covers technical details, affected versions, impact assessment, 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-98178 Overview

CVE-2026-98178 is a null pointer dereference vulnerability in the Linux kernel's AMD GPU driver (drm/amdgpu). The flaw resides in amdgpu_amdkfd_clear_kfd_mapping(), which assumes a non-NULL kfd_dev has a fully populated node array. This assumption fails when Kernel Fusion Driver (KFD) device initialization aborts after probe. On Polaris systems without the required PCIe atomics support, kgd2kfd_device_init() sets num_nodes before allocation and returns early. A subsequent GPU reset then dereferences nodes[0]->id, triggering a kernel oops.

Critical Impact

Local triggering of the code path during a GPU reset causes a kernel null pointer dereference, leading to denial of service on affected AMD Polaris hardware.

Affected Products

  • Linux kernel versions containing the amdgpu_amdkfd_clear_kfd_mapping() function prior to the patch
  • AMD GPU driver (drm/amdgpu) with KFD support
  • Systems using AMD Polaris GPUs lacking PCIe atomics support

Discovery Timeline

  • 2026-10-06 - CVE-2026-98178 published to NVD
  • 2026-10-06 - Last updated in NVD database

Technical Details for CVE-2026-98178

Vulnerability Analysis

The vulnerability sits in the AMD GPU Kernel Fusion Driver (KFD) initialization and teardown logic. The function amdgpu_amdkfd_clear_kfd_mapping() iterates the nodes array attached to a kfd_dev structure. It relies on num_nodes as the loop bound without verifying whether KFD initialization actually completed. When probe begins, kgd2kfd_device_init() populates num_nodes early. If a prerequisite check later fails, the function returns before allocating nodes[0].

The kfd_dev structure remains attached to the parent amdgpu device despite the aborted initialization. Any later code path that calls amdgpu_amdkfd_clear_kfd_mapping(), such as a GPU reset handler, walks the nodes array and dereferences a NULL pointer at nodes[0]->id. This produces a kernel null pointer dereference and panics the running kernel on affected hardware.

Root Cause

The root cause is missing validation of KFD initialization state before iterating nodes[]. The code trusts num_nodes as authoritative but that counter is set before node allocation succeeds. The fix requires the authoritative KFD initialization flag before walking the node array, matching the pattern already used in KFD reset and teardown paths.

Attack Vector

Triggering the dereference requires local conditions on affected AMD Polaris systems: KFD probe must fail the PCIe atomics check, and a GPU reset must subsequently occur. The vulnerability is a kernel robustness defect rather than a remotely reachable primitive. Impact is limited to denial of service through kernel crash.

No verified exploit code is available. The fix is committed upstream; see the kernel commit 7f9caa7 and kernel commit 157d3f1 for the resolved patch (cherry-picked from 4ac1835823c47903fbb278bbf474773c46f59edc).

Detection Methods for CVE-2026-98178

Indicators of Compromise

  • Kernel oops or panic logs referencing amdgpu_amdkfd_clear_kfd_mapping in the stack trace
  • dmesg entries indicating KFD initialization aborted due to missing PCIe atomics on AMD Polaris GPUs
  • GPU reset events immediately followed by null pointer dereference faults in the amdgpu module

Detection Strategies

  • Audit running kernel versions against the fixed commits in git.kernel.org stable trees
  • Inventory systems using AMD Polaris GPUs and verify PCIe atomics capability of the host platform
  • Correlate kernel crash dumps with the amdgpu/amdkfd subsystem to identify affected hosts

Monitoring Recommendations

  • Forward kern.log and dmesg output to a central log store and alert on amdgpu module faults
  • Monitor host uptime and unexpected reboot patterns on Linux workstations and compute nodes with AMD GPUs
  • Track GPU reset frequency on affected hardware classes to surface pre-crash conditions

How to Mitigate CVE-2026-98178

Immediate Actions Required

  • Identify Linux hosts running AMD Polaris GPUs with the amdgpu driver and KFD enabled
  • Apply the upstream kernel patch or upgrade to a stable kernel release containing the fix
  • Validate that custom or downstream kernels have incorporated commit 4ac1835823c47903fbb278bbf474773c46f59edc

Patch Information

The fix is upstream in the Linux kernel stable tree. Reference the Kernel Git Commit 7f9caa7 and Kernel Git Commit 157d3f1. The patch requires checking the authoritative KFD initialization flag before iterating nodes[], aligning amdgpu_amdkfd_clear_kfd_mapping() with existing KFD reset and teardown paths.

Workarounds

  • Disable KFD support on Polaris systems lacking PCIe atomics where it is not required
  • Avoid triggering GPU resets on unpatched hosts by stabilizing GPU workloads and driver interactions
  • Pin affected systems to vendor kernels that already carry the stable backport

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.