]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
drm/xe: Make usm.asid_to_vm allocation use GFP_NOWAIT
authorMatthew Brost <matthew.brost@intel.com>
Fri, 16 Jan 2026 22:17:22 +0000 (14:17 -0800)
committerMatthew Brost <matthew.brost@intel.com>
Sat, 17 Jan 2026 02:24:45 +0000 (18:24 -0800)
Ensure the asid_to_vm lookup is reclaim-safe so it can be performed
during TLB invalidations, which is necessary for context-based TLB
invalidation support.

Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Stuart Summers <stuart.summers@intel.com>
Tested-by: Stuart Summers <stuart.summers@intel.com>
Link: https://patch.msgid.link/20260116221731.868657-3-matthew.brost@intel.com
drivers/gpu/drm/xe/xe_vm.c

index bbbc7e71b8ef4f5b6fb29070c373b27ed8b2d8ed..24647b128a17f25bdebcc68384a7afe03da3d222 100644 (file)
@@ -1653,7 +1653,7 @@ struct xe_vm *xe_vm_create(struct xe_device *xe, u32 flags, struct xe_file *xef)
                down_write(&xe->usm.lock);
                err = xa_alloc_cyclic(&xe->usm.asid_to_vm, &asid, vm,
                                      XA_LIMIT(1, XE_MAX_ASID - 1),
-                                     &xe->usm.next_asid, GFP_KERNEL);
+                                     &xe->usm.next_asid, GFP_NOWAIT);
                up_write(&xe->usm.lock);
                if (err < 0)
                        goto err_close;