aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/linux-yocto-4.19.8/1270-drm-amdgpu-Set-DPM_FLAG_NEVER_SKIP-when-enabling-PM-.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/linux-yocto-4.19.8/1270-drm-amdgpu-Set-DPM_FLAG_NEVER_SKIP-when-enabling-PM-.patch')
-rw-r--r--common/recipes-kernel/linux/linux-yocto-4.19.8/1270-drm-amdgpu-Set-DPM_FLAG_NEVER_SKIP-when-enabling-PM-.patch36
1 files changed, 36 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/linux-yocto-4.19.8/1270-drm-amdgpu-Set-DPM_FLAG_NEVER_SKIP-when-enabling-PM-.patch b/common/recipes-kernel/linux/linux-yocto-4.19.8/1270-drm-amdgpu-Set-DPM_FLAG_NEVER_SKIP-when-enabling-PM-.patch
new file mode 100644
index 00000000..db1f7711
--- /dev/null
+++ b/common/recipes-kernel/linux/linux-yocto-4.19.8/1270-drm-amdgpu-Set-DPM_FLAG_NEVER_SKIP-when-enabling-PM-.patch
@@ -0,0 +1,36 @@
+From 0231e470b3dff703333c4a7cc94c240c9b4eb197 Mon Sep 17 00:00:00 2001
+From: Alex Deucher <alexander.deucher@amd.com>
+Date: Mon, 18 Feb 2019 17:11:38 -0500
+Subject: [PATCH 1270/2940] drm/amdgpu: Set DPM_FLAG_NEVER_SKIP when enabling
+ PM-runtime
+
+Based on a similar patch from Rafael for radeon.
+
+When using ATPX to control dGPU power, the state is not retained
+across suspend and resume cycles by default. This can probably
+be loosened for Hybrid Graphics (_PR3) laptops where I think the
+state is properly retained.
+
+Fixes: c62ec4610c40 ("PM / core: Fix direct_complete handling for devices with no callbacks")
+Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
+Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
+index 39a7873f2fca..75dd9885c65d 100644
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
+@@ -209,6 +209,7 @@ int amdgpu_driver_load_kms(struct drm_device *dev, unsigned long flags)
+ }
+
+ if (amdgpu_device_is_px(dev)) {
++ dev_pm_set_driver_flags(dev->dev, DPM_FLAG_NEVER_SKIP);
+ pm_runtime_use_autosuspend(dev->dev);
+ pm_runtime_set_autosuspend_delay(dev->dev, 5000);
+ pm_runtime_set_active(dev->dev);
+--
+2.17.1
+