Change-Id: I8ce8b16e77cacc914982fa0986b055eb31d6a390
Signed-off-by: Rex Zhu <rex....@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/ci_dpm.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/ci_dpm.c 
b/drivers/gpu/drm/amd/amdgpu/ci_dpm.c
index 34e5b67..54a7019 100644
--- a/drivers/gpu/drm/amd/amdgpu/ci_dpm.c
+++ b/drivers/gpu/drm/amd/amdgpu/ci_dpm.c
@@ -2207,6 +2207,11 @@ static int ci_upload_firmware(struct amdgpu_device *adev)
        struct ci_power_info *pi = ci_get_pi(adev);
        int i, ret;
 
+       if (amdgpu_ci_is_smc_running(adev)) {
+               DRM_INFO("smc is running, no need to load smc firmware\n");
+               return 0;
+       }
+
        for (i = 0; i < adev->usec_timeout; i++) {
                if (RREG32_SMC(ixRCU_UC_EVENTS) & 
RCU_UC_EVENTS__boot_seq_done_MASK)
                        break;
@@ -5275,8 +5280,6 @@ static int ci_dpm_enable(struct amdgpu_device *adev)
        struct amdgpu_ps *boot_ps = adev->pm.dpm.boot_ps;
        int ret;
 
-       if (amdgpu_ci_is_smc_running(adev))
-               return -EINVAL;
        if (pi->voltage_control != CISLANDS_VOLTAGE_CONTROL_NONE) {
                ci_enable_voltage_control(adev);
                ret = ci_construct_voltage_tables(adev);
-- 
1.9.1

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Reply via email to