{"id":"CVE-2026-98510","state":"PUBLISHED","title":"drm/xe/vm: nuke PTs only after unlinking contested VMAs","description":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/xe/vm: nuke PTs only after unlinking contested VMAs\n\nIn xe_vm_close_and_put(), external-BO VMAs are queued on the contested\nlist for deferred destruction via xe_vma_destroy_unlocked(). However,\nxe_vm_pt_destroy() was previously invoked before processing contested\nVMAs, destroying vm->pt_root while those VMAs were still linked to their\nrespective buffer objects (vm_bo->list.gpuva).\n\nIf a concurrent thread evicts one of those shared buffer objects,\nxe_bo_trigger_rebind() holding only bo->resv walks the BO's VMAs and, in\nfault mode, calls xe_vm_invalidate_vma() -> xe_pt_zap_ptes(). Because\nvm->pt_root[tile->id] is already NULL, dereferencing pt->level causes a\nNULL ptr deref.\n\nFix this by deferring xe_vm_free_scratch() and xe_vm_pt_destroy() until\nafter all contested VMAs have been unlinked and destroyed.\n\nUser is reporting hitting a NULL ptr deref in xe_pt_zap_ptes(), which\ncould be explained by this race.\n\n(cherry picked from commit c2863648959489767f08892fd6e90577d2ea0b6a)","publishedAt":"2026-10-18T15:17:20.805Z","updatedAt":"2026-10-24T14:09:11.598Z","severity":{"score":7.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"70fddc065ac80845ffd33095b3635d59883cf7e6","versionType":"git"},{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"ba678c2b02e0d36b53deb5a6d5e5ea044d36def7","versionType":"git"},{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"bddaa5e4094c134452c29e20a26c4718827e4cb1","versionType":"git"},{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"24a22fb3c731474b68e986af6804db450fb88617","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_vm.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.8","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.8","versionType":"semver"},{"version":"6.12.112","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.55","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.2.9","status":"unaffected","lessThanOrEqual":"7.2.*","versionType":"semver"},{"version":"7.3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_vm.c"]}],"references":["https://git.kernel.org/stable/c/70fddc065ac80845ffd33095b3635d59883cf7e6","https://git.kernel.org/stable/c/ba678c2b02e0d36b53deb5a6d5e5ea044d36def7","https://git.kernel.org/stable/c/bddaa5e4094c134452c29e20a26c4718827e4cb1","https://git.kernel.org/stable/c/24a22fb3c731474b68e986af6804db450fb88617"],"weaknesses":[],"ingestedAt":"2026-10-29T20:13:43.249Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/98xxx/CVE-2026-98510.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-98510","state":"PUBLISHED","datePublished":"2026-10-18T15:17:20.805Z","dateUpdated":"2026-10-24T14:09:11.598Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-09-25T10:25:14.354Z"},"containers":{"cna":{"title":"drm/xe/vm: nuke PTs only after unlinking contested VMAs","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/xe/vm: nuke PTs only after unlinking contested VMAs\n\nIn xe_vm_close_and_put(), external-BO VMAs are queued on the contested\nlist for deferred destruction via xe_vma_destroy_unlocked(). However,\nxe_vm_pt_destroy() was previously invoked before processing contested\nVMAs, destroying vm->pt_root while those VMAs were still linked to their\nrespective buffer objects (vm_bo->list.gpuva).\n\nIf a concurrent thread evicts one of those shared buffer objects,\nxe_bo_trigger_rebind() holding only bo->resv walks the BO's VMAs and, in\nfault mode, calls xe_vm_invalidate_vma() -> xe_pt_zap_ptes(). Because\nvm->pt_root[tile->id] is already NULL, dereferencing pt->level causes a\nNULL ptr deref.\n\nFix this by deferring xe_vm_free_scratch() and xe_vm_pt_destroy() until\nafter all contested VMAs have been unlinked and destroyed.\n\nUser is reporting hitting a NULL ptr deref in xe_pt_zap_ptes(), which\ncould be explained by this race.\n\n(cherry picked from commit c2863648959489767f08892fd6e90577d2ea0b6a)"}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"70fddc065ac80845ffd33095b3635d59883cf7e6","versionType":"git"},{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"ba678c2b02e0d36b53deb5a6d5e5ea044d36def7","versionType":"git"},{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"bddaa5e4094c134452c29e20a26c4718827e4cb1","versionType":"git"},{"version":"b06d47be7c83165d3b3e45e1d5f9520b79c7f5cc","status":"affected","lessThan":"24a22fb3c731474b68e986af6804db450fb88617","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_vm.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.8","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.8","versionType":"semver"},{"version":"6.12.112","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.55","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.2.9","status":"unaffected","lessThanOrEqual":"7.2.*","versionType":"semver"},{"version":"7.3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/gpu/drm/xe/xe_vm.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/70fddc065ac80845ffd33095b3635d59883cf7e6"},{"url":"https://git.kernel.org/stable/c/ba678c2b02e0d36b53deb5a6d5e5ea044d36def7"},{"url":"https://git.kernel.org/stable/c/bddaa5e4094c134452c29e20a26c4718827e4cb1"},{"url":"https://git.kernel.org/stable/c/24a22fb3c731474b68e986af6804db450fb88617"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - A local render-node client reaches the patched xe_vm_close_and_put() through DRM_IOCTL_XE_VM_DESTROY -> xe_vm_destroy_ioctl() or file close -> xe_file_close(); the competing path is another local DRM ioctl, not wire-supplied data.\nAC:L - The same client can bind an external BO to a fault-mode VM and race VM_DESTROY against PREFETCH from a second VM; PREFETCH reaches xe_bo_migrate() -> xe_bo_move_notify() -> xe_bo_trigger_rebind(), so the attacker controls both sides.\nPR:L - XE_VM_CREATE, XE_GEM_CREATE, XE_VM_BIND, and XE_VM_DESTROY are registered with DRM_RENDER_ALLOW and contain no capability or DRM-authentication check, making the path available to an unprivileged user with render-node access.\nUI:N - The attacking process creates the VM and external BO, establishes the immediate mapping, and issues both the destroy and migration operations itself; no victim action is required.\nS:U - The fault occurs in the host xe DRM driver while processing that driver's local render-node operations and does not cross a VM, IOMMU, or other security authority boundary.\nC:H - xe_vm_close_and_put() leaves the VMA linked while xe_pt_destroy() recursively kfree()s PT nodes with vm->pt_root still published; a racing xe_pt_zap_ptes() can therefore walk heap-groomable freed PT metadata and dereference stale object pointers.\nI:H - In the UAF interleaving, xe_pt_zap_ptes_entry() uses the freed metadata's xe_child->bo->vmap as the destination for xe_map_memset(), allowing a groomed stale pointer to redirect writes and potentially corrupt control flow.\nA:H - In the documented interleaving, xe_vm_pt_destroy() sets vm->pt_root[tile->id] to NULL and xe_pt_zap_ptes() dereferences pt->level, producing the reported kernel NULL-pointer oops."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-10-24T14:09:11.598Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.8","versionEndExcluding":"6.12.112"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.8","versionEndExcluding":"6.18.55"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.8","versionEndExcluding":"7.2.9"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.8","versionEndExcluding":"7.3"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}