drm/amdgpu/si/dpm: fix swapped ck enable

Submitted by StDenis, Tom on Sept. 14, 2016, 1:56 p.m.

Details

Message ID CY4PR12MB1768C94E4215E44C6F5DF704F7F10@CY4PR12MB1768.namprd12.prod.outlook.com
State New
Headers show
Series "drm/amdgpu/si/dpm: fix swapped ck enable" ( rev: 2 ) in AMD X.Org drivers

Not browsing as part of any series.

Commit Message

StDenis, Tom Sept. 14, 2016, 1:56 p.m.
Yup, that looks better.  My apologies.  Guess that's the downside of having assertions for enable and disable in the same driver.


Reviewed-by: Tom St Denis <tom.stdenis@amd.com>

Patch hide | download patch | download mbox

diff --git a/drivers/gpu/drm/amd/amdgpu/si_smc.c b/drivers/gpu/drm/amd/amdgpu/si_smc.c
index 2cc628c..47bbb40 100644
--- a/drivers/gpu/drm/amd/amdgpu/si_smc.c
+++ b/drivers/gpu/drm/amd/amdgpu/si_smc.c
@@ -143,9 +143,9 @@  void si_smc_clock(struct amdgpu_device *adev, bool enable)
         u32 tmp = RREG32_SMC(SMC_SYSCON_CLOCK_CNTL_0);

         if (enable)
-               tmp |= CK_DISABLE;
-       else
                 tmp &= ~CK_DISABLE;
+       else
+               tmp |= CK_DISABLE;

         WREG32_SMC(SMC_SYSCON_CLOCK_CNTL_0, tmp);
 }