]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
drm/amd/powerplay: check whether enable dpm in powerplay.
authorRex Zhu <Rex.Zhu@amd.com>
Mon, 23 Nov 2015 06:50:10 +0000 (14:50 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 21 Dec 2015 21:42:50 +0000 (16:42 -0500)
Change-Id: I0a2dbf8ef7d4a3e9788fe211fc5964dd2487c519
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c

index 6cbbae7367f77a87e34827ca51c8cca1c3adfdc1..b8b4a4781f4d112d642bad11952a6d16167a5c2e 100644 (file)
@@ -145,8 +145,11 @@ static int amdgpu_pp_sw_init(void *handle)
 
 #ifdef CONFIG_DRM_AMD_POWERPLAY
        if (adev->pp_enabled) {
-               adev->pm.dpm_enabled = true;
                amdgpu_pm_sysfs_init(adev);
+               if (amdgpu_dpm == 0)
+                       adev->pm.dpm_enabled = false;
+               else
+                       adev->pm.dpm_enabled = true;
        }
 #endif