From: Rex Zhu Date: Mon, 23 Nov 2015 06:50:10 +0000 (+0800) Subject: drm/amd/powerplay: check whether enable dpm in powerplay. X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=1ea6c1e8e40c5cccc3572d1221c0770fc0c437f3;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git drm/amd/powerplay: check whether enable dpm in powerplay. Change-Id: I0a2dbf8ef7d4a3e9788fe211fc5964dd2487c519 Signed-off-by: Rex Zhu --- 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