aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
diff options
context:
space:
mode:
authorPrike Liang <Prike.Liang@amd.com>2019-05-27 04:05:50 -0400
committerAlex Deucher <alexander.deucher@amd.com>2019-06-05 12:14:15 -0400
commit1929059893022a3bbed43934c7313e66aad7346b (patch)
tree34ddbd719ad1598970a1ea0676353f8ff8d65c9e /drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
parent1019fe047a483ecfdc82661802e56871f649c46e (diff)
drm/amd/amdgpu: add RLC firmware to support raven1 refresh
Use SMU firmware version to indentify the raven1 refresh device and then load homologous RLC FW. Signed-off-by: Prike Liang <Prike.Liang@amd.com> Suggested-by: Huang Rui<Ray.Huang@amd.com> Reviewed-by: Huang Rui <ray.huang@amd.com> Reviewed-by: Evan Quan <evan.quan@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
index 34471dbaa872..039cfa2ec89d 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
@@ -2490,6 +2490,21 @@ void amdgpu_pm_print_power_states(struct amdgpu_device *adev)
2490 2490
2491} 2491}
2492 2492
2493int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, uint32_t *smu_version)
2494{
2495 int r = -EINVAL;
2496
2497 if (adev->powerplay.pp_funcs && adev->powerplay.pp_funcs->load_firmware) {
2498 r = adev->powerplay.pp_funcs->load_firmware(adev->powerplay.pp_handle);
2499 if (r) {
2500 pr_err("smu firmware loading failed\n");
2501 return r;
2502 }
2503 *smu_version = adev->pm.fw_version;
2504 }
2505 return r;
2506}
2507
2493int amdgpu_pm_sysfs_init(struct amdgpu_device *adev) 2508int amdgpu_pm_sysfs_init(struct amdgpu_device *adev)
2494{ 2509{
2495 struct pp_hwmgr *hwmgr = adev->powerplay.pp_handle; 2510 struct pp_hwmgr *hwmgr = adev->powerplay.pp_handle;