diff options
author | 2014-11-07 12:56:00 -0500 | |
---|---|---|
committer | 2014-11-12 11:56:40 -0500 | |
commit | c0392f8f0971fee63fa736c800e7c32b59773ba7 (patch) | |
tree | 7d2f875a919efd71ec46ebc30f7ad1f86c486e12 /drivers/gpu/drm | |
parent | drm/radeon: fix dram timing for certain hawaii boards (diff) | |
download | linux-dev-c0392f8f0971fee63fa736c800e7c32b59773ba7.tar.xz linux-dev-c0392f8f0971fee63fa736c800e7c32b59773ba7.zip |
drm/radeon: improve mclk param calcuations for ci dpm
Properly take into account the post divider.
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r-- | drivers/gpu/drm/radeon/ci_dpm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/radeon/ci_dpm.c b/drivers/gpu/drm/radeon/ci_dpm.c index 4dd8f3575238..3705d13218e6 100644 --- a/drivers/gpu/drm/radeon/ci_dpm.c +++ b/drivers/gpu/drm/radeon/ci_dpm.c @@ -2409,10 +2409,10 @@ static int ci_calculate_mclk_params(struct radeon_device *rdev, u32 tmp; u32 reference_clock = rdev->clock.mpll.reference_freq; - if (pi->mem_gddr5) - freq_nom = memory_clock * 4; + if (mpll_param.qdr == 1) + freq_nom = memory_clock * 4 * (1 << mpll_param.post_div); else - freq_nom = memory_clock * 2; + freq_nom = memory_clock * 2 * (1 << mpll_param.post_div); tmp = (freq_nom / reference_clock); tmp = tmp * tmp; |