diff options
author | Alex Deucher <alexander.deucher@amd.com> | 2013-08-21 10:02:32 -0400 |
---|---|---|
committer | Christian König <christian.koenig@amd.com> | 2014-02-18 10:11:30 -0500 |
commit | 82f79cc54b6a67c0b17aff4fb5ed43155ff3f0ea (patch) | |
tree | 6e986d77466b1f668cc47ea1f08c2868cedd4fab /drivers/gpu/drm/radeon/rv770_dpm.c | |
parent | b59b733397cac70be5b04c60e8810077ac6ca48d (diff) |
drm/radeon/dpm: move platform caps fetching to a separate function
It's needed by by both the asic specific functions and the
extended table parser.
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/rv770_dpm.c')
-rw-r--r-- | drivers/gpu/drm/radeon/rv770_dpm.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/gpu/drm/radeon/rv770_dpm.c b/drivers/gpu/drm/radeon/rv770_dpm.c index 5b2ea8ac0731..9098c86ca006 100644 --- a/drivers/gpu/drm/radeon/rv770_dpm.c +++ b/drivers/gpu/drm/radeon/rv770_dpm.c | |||
@@ -2281,9 +2281,6 @@ int rv7xx_parse_power_table(struct radeon_device *rdev) | |||
2281 | power_info->pplib.ucNumStates, GFP_KERNEL); | 2281 | power_info->pplib.ucNumStates, GFP_KERNEL); |
2282 | if (!rdev->pm.dpm.ps) | 2282 | if (!rdev->pm.dpm.ps) |
2283 | return -ENOMEM; | 2283 | return -ENOMEM; |
2284 | rdev->pm.dpm.platform_caps = le32_to_cpu(power_info->pplib.ulPlatformCaps); | ||
2285 | rdev->pm.dpm.backbias_response_time = le16_to_cpu(power_info->pplib.usBackbiasTime); | ||
2286 | rdev->pm.dpm.voltage_response_time = le16_to_cpu(power_info->pplib.usVoltageTime); | ||
2287 | 2284 | ||
2288 | for (i = 0; i < power_info->pplib.ucNumStates; i++) { | 2285 | for (i = 0; i < power_info->pplib.ucNumStates; i++) { |
2289 | power_state = (union pplib_power_state *) | 2286 | power_state = (union pplib_power_state *) |
@@ -2361,6 +2358,10 @@ int rv770_dpm_init(struct radeon_device *rdev) | |||
2361 | pi->min_vddc_in_table = 0; | 2358 | pi->min_vddc_in_table = 0; |
2362 | pi->max_vddc_in_table = 0; | 2359 | pi->max_vddc_in_table = 0; |
2363 | 2360 | ||
2361 | ret = r600_get_platform_caps(rdev); | ||
2362 | if (ret) | ||
2363 | return ret; | ||
2364 | |||
2364 | ret = rv7xx_parse_power_table(rdev); | 2365 | ret = rv7xx_parse_power_table(rdev); |
2365 | if (ret) | 2366 | if (ret) |
2366 | return ret; | 2367 | return ret; |