drm/amd/pm: enable lclk dpm/ds and BACO features for SMU 13.0.0
authorEvan Quan <evan.quan@amd.com>
Mon, 25 Apr 2022 08:43:45 +0000 (16:43 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 10 May 2022 21:53:10 +0000 (17:53 -0400)
Enable those features supported by latest PMFW 78.34.0.

Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Likun Gao <Likun.Gao@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c

index b595497e9bf55f7c2c0b189af41514ae377af1bf..71312ed26fb9520569a37b032212570e3345ddd8 100644 (file)
@@ -256,6 +256,13 @@ smu_v13_0_0_get_allowed_feature_mask(struct smu_context *smu,
        *(uint64_t *)feature_mask |= FEATURE_MASK(FEATURE_DPM_DCN_BIT);
        *(uint64_t *)feature_mask |= FEATURE_MASK(FEATURE_DS_DCFCLK_BIT);
 
+       if (adev->pm.pp_feature & PP_PCIE_DPM_MASK) {
+               *(uint64_t *)feature_mask |= FEATURE_MASK(FEATURE_DPM_LINK_BIT);
+               *(uint64_t *)feature_mask |= FEATURE_MASK(FEATURE_DS_LCLK_BIT);
+       }
+
+       *(uint64_t *)feature_mask |= FEATURE_MASK(FEATURE_BACO_BIT);
+
        return 0;
 }