summaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorRex Zhu <Rex.Zhu@amd.com>2015-11-23 14:50:10 +0800
committerAlex Deucher <alexander.deucher@amd.com>2015-12-21 16:42:50 -0500
commit1ea6c1e8e40c5cccc3572d1221c0770fc0c437f3 (patch)
tree8106158b72d210cc8a46593c86235622f8c27208 /drivers/gpu
parent7ad4e7f09372946d1bfd5359c45ccce024d0689e (diff)
downloadlinux-1ea6c1e8e40c5cccc3572d1221c0770fc0c437f3.tar.gz
linux-1ea6c1e8e40c5cccc3572d1221c0770fc0c437f3.tar.bz2
linux-1ea6c1e8e40c5cccc3572d1221c0770fc0c437f3.zip
drm/amd/powerplay: check whether enable dpm in powerplay.
Change-Id: I0a2dbf8ef7d4a3e9788fe211fc5964dd2487c519 Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c
index 6cbbae7367f7..b8b4a4781f4d 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_powerplay.c
@@ -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