]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
drm/xe: Enable D3Cold on 'low' VRAM utilization
authorRodrigo Vivi <rodrigo.vivi@intel.com>
Wed, 22 May 2024 17:01:05 +0000 (13:01 -0400)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Thu, 23 May 2024 15:54:08 +0000 (11:54 -0400)
Now that we eliminated all the mem_access get/put with its
locking issues from the inner calls of migration, we can
allow D3Cold.

Enable it when VRAM utilization is lower then 300Mb. On
higher utilization we only allow D3hot so we don't increase
so much the latency on runtime resume due to the memory
restoration.

Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Anshuman Gupta <anshuman.gupta@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240522170105.327472-7-rodrigo.vivi@intel.com
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/xe/xe_pm.h

index f694005db2782db107ec9fc36adb5f67e73c937d..104a21ae6dfd072da850c27890c1a0a7a14148bd 100644 (file)
@@ -8,12 +8,7 @@
 
 #include <linux/pm_runtime.h>
 
-/*
- * TODO: Threshold = 0 will block D3Cold.
- *       Before we can move this to a higher value (like 300), we need to:
- *           1. rewrite the VRAM save / restore to avoid buffer object locks
- */
-#define DEFAULT_VRAM_THRESHOLD 0 /* in MB */
+#define DEFAULT_VRAM_THRESHOLD 300 /* in MB */
 
 struct xe_device;