drm/amdkfd: Add TLB flush after MES queue eviction/suspension
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ cc009e613de6560eb499f8bc92c80a737752cb30 · < 94e25cb6ab7f4f025bcdcd8ea79fda30f12843a4| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
drm/amdkfd: Add TLB flush after MES queue eviction/suspension
MES (Micro Engine Scheduler) does not perform heavy-weight TLB invalidation after unmapping queues, unlike HWS which does this automatically. This causes a race condition where in-flight DMA descriptors can access memory that has been unmapped, leading to page faults and GPU queue hangs during SVM page migration.
The issue manifests as KFDSVMRangeTest.MultiThreadMigrationTest failures on gfx1151 (Strix Point) with XNACK mode 1 enabled - the GPU compute queue hangs with packets submitted but never consumed.
Add kfd_flush_tlb() calls after MES queue removal in two locations: - evict_process_queues_cpsch(): after all queues removed during eviction - suspend_queues(): after debug/criu queue suspension (with mem_fence barrier)
This ensures all in-flight memory accesses from unmapped queues are flushed before memory is freed or migrated.
(cherry picked from commit f5c4f88e0f9c45a8fb9dfac0c1df726c95e41b77)
From the CVE record · Linux
The Linux kernel’s drm/amdkfd MES queue handling can leave in-flight DMA accesses pointing to unmapped memory during SVM page migration, causing page faults and GPU compute queue hangs. The issue was observed on gfx1151 (Strix Point) with XNACK mode 1 enabled. The input does not describe an attacker path, authentication requirements, or user interaction.
Engineers running Linux kernels with drm/amdkfd on affected GPU configurations should check their kernel; affected versions are not specified.