drm/amd/powerplay: disable fw dstate when gfxoff is enabled
authorJack Xiao <Jack.Xiao@amd.com>
Tue, 28 May 2019 13:47:05 +0000 (21:47 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 21 Jun 2019 23:59:33 +0000 (18:59 -0500)
SMU FW has bug that it would cause hung when both fw dstate and
gfxoff are enabled at the same time.

Signed-off-by: Jack Xiao <Jack.Xiao@amd.com>
Reviewed-by: Kenneth Feng <kenneth.feng@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/navi10_ppt.c

index 5b4332392cf59b0c0e6435c35c472f936f96d0d6..4310f8621061e4f99689e5c8df07f7ed8a46f44b 100644 (file)
@@ -336,9 +336,12 @@ navi10_get_allowed_feature_mask(struct smu_context *smu,
                                | FEATURE_MASK(FEATURE_FW_DSTATE_BIT)
                                | FEATURE_MASK(FEATURE_ACDC_BIT);
 
-       if (adev->pm.pp_feature & PP_GFXOFF_MASK)
+       if (adev->pm.pp_feature & PP_GFXOFF_MASK) {
                *(uint64_t *)feature_mask |= FEATURE_MASK(FEATURE_GFX_SS_BIT)
                                | FEATURE_MASK(FEATURE_GFXOFF_BIT);
+               /* TODO: remove it once fw fix the bug */
+               *(uint64_t *)feature_mask &= ~FEATURE_MASK(FEATURE_FW_DSTATE_BIT);
+       }
 
        if (smu->adev->pg_flags & AMD_PG_SUPPORT_VCN)
                *(uint64_t *)feature_mask |= FEATURE_MASK(FEATURE_VCN_PG_BIT);