drm/xe: Add drm_gpusvm_devmem to xe_bo
authorMatthew Brost <matthew.brost@intel.com>
Thu, 6 Mar 2025 01:26:47 +0000 (17:26 -0800)
committerMatthew Brost <matthew.brost@intel.com>
Thu, 6 Mar 2025 19:35:56 +0000 (11:35 -0800)
Add drm_gpusvm_devmem to xe_bo. Required to enable SVM migrations.

Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250306012657.3505757-23-matthew.brost@intel.com
drivers/gpu/drm/xe/xe_bo_types.h

index 60c522866500c50142473c51919fedcf8cd5e045..15a92e3d4898582d406e7b5df7c0f837e4c74aed 100644 (file)
@@ -8,6 +8,7 @@
 
 #include <linux/iosys-map.h>
 
+#include <drm/drm_gpusvm.h>
 #include <drm/ttm/ttm_bo.h>
 #include <drm/ttm/ttm_device.h>
 #include <drm/ttm/ttm_placement.h>
@@ -80,6 +81,9 @@ struct xe_bo {
         */
        u16 cpu_caching;
 
+       /** @devmem_allocation: SVM device memory allocation */
+       struct drm_gpusvm_devmem devmem_allocation;
+
        /** @vram_userfault_link: Link into @mem_access.vram_userfault.list */
                struct list_head vram_userfault_link;