drm/radeon/dpm/rs780: fix force_performance state for same sclks
authorAlex Deucher <alexander.deucher@amd.com>
Fri, 13 Sep 2013 15:04:28 +0000 (11:04 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 16 Sep 2013 00:27:51 +0000 (20:27 -0400)
If the low and high sclks within a power state are the same,
there no need to enable sclk scaling.  Enabling sclk scaling
can cause display stability issues on some boards.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
drivers/gpu/drm/radeon/rs780_dpm.c

index eb336bf5a54e91e79ad45b290632e495e6a2bb0a..6af8505cf4d2db624ee64811ba4575158d90e974 100644 (file)
@@ -1043,8 +1043,10 @@ int rs780_dpm_force_performance_level(struct radeon_device *rdev,
                if (pi->voltage_control)
                        rs780_force_voltage(rdev, pi->max_voltage);
 
-               WREG32_P(FVTHROT_FBDIV_REG1, 0, ~FORCE_FEEDBACK_DIV);
-               rs780_clk_scaling_enable(rdev, true);
+               if (ps->sclk_high != ps->sclk_low) {
+                       WREG32_P(FVTHROT_FBDIV_REG1, 0, ~FORCE_FEEDBACK_DIV);
+                       rs780_clk_scaling_enable(rdev, true);
+               }
 
                if (pi->voltage_control) {
                        rs780_voltage_scaling_enable(rdev, true);