drm/amd/powrplay: fix issue that get wrong enable flag.
authorRex Zhu <Rex.Zhu@amd.com>
Tue, 15 Mar 2016 09:42:47 +0000 (17:42 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 5 May 2016 00:28:13 +0000 (20:28 -0400)
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c

index d08f739..446ed72 100644 (file)
@@ -3960,14 +3960,11 @@ static int polaris10_trim_single_dpm_states(struct pp_hwmgr *hwmgr,
                        uint32_t low_limit, uint32_t high_limit)
 {
        uint32_t i;
-       struct polaris10_hwmgr *data = (struct polaris10_hwmgr *)(hwmgr->backend);
 
        for (i = 0; i < dpm_table->count; i++) {
                if ((dpm_table->dpm_levels[i].value < low_limit)
                || (dpm_table->dpm_levels[i].value > high_limit))
                        dpm_table->dpm_levels[i].enabled = false;
-               else if (((1 << i) & data->disable_dpm_mask) == 0)
-                       dpm_table->dpm_levels[i].enabled = false;
                else
                        dpm_table->dpm_levels[i].enabled = true;
        }