drm/amd/powerplay: unload mp1 for Arcturus RAS baco reset
authorEvan Quan <evan.quan@amd.com>
Tue, 24 Mar 2020 08:22:19 +0000 (16:22 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 9 Apr 2020 14:43:18 +0000 (10:43 -0400)
This sequence is recommended by PMFW team for the baco reset
with PMFW reloaded. And it seems able to address the random
failure seen on Arcturus.

Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Feifei Xu <Feifei.Xu@amd.com>
Reviewed-by: John Clements <John.Clements@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/smu_v11_0.c

index 541c932a60051bb9c00215ca22e7924892c1d355..655ba4fb05dcdf330e53c3548e54681a18a58208 100644 (file)
@@ -1718,6 +1718,12 @@ int smu_v11_0_baco_set_state(struct smu_context *smu, enum smu_baco_state state)
                if (ret)
                        goto out;
 
+               if (ras && ras->supported) {
+                       ret = smu_send_smc_msg(smu, SMU_MSG_PrepareMp1ForUnload, NULL);
+                       if (ret)
+                               goto out;
+               }
+
                /* clear vbios scratch 6 and 7 for coming asic reinit */
                WREG32(adev->bios_scratch_reg_offset + 6, 0);
                WREG32(adev->bios_scratch_reg_offset + 7, 0);