diff options
author | Evan Quan <evan.quan@amd.com> | 2020-07-07 06:48:06 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2020-07-21 22:37:38 +0300 |
commit | 28251d726b2be5f9f982b649c8cc00f20936a326 (patch) | |
tree | 5c18384e3e5cb97bd81a56d7219d5f357cf3f47a /drivers/gpu/drm/amd/powerplay/smu_v12_0.c | |
parent | b4bb3aaf04afbe649bf4f4188247dcbfd95b2f4d (diff) | |
download | linux-28251d726b2be5f9f982b649c8cc00f20936a326.tar.xz |
drm/amd/powerplay: implement smu_cmn_get_enabled_mask() for all ASICs
Instead of having each for smu v11 and v12.
Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/powerplay/smu_v12_0.c')
-rw-r--r-- | drivers/gpu/drm/amd/powerplay/smu_v12_0.c | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c index 7286edec2789..33ec9fc44f4c 100644 --- a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c +++ b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c @@ -296,29 +296,6 @@ int smu_v12_0_set_default_dpm_tables(struct smu_context *smu) return smu_update_table(smu, SMU_TABLE_DPMCLOCKS, 0, smu_table->clocks_table, false); } -int smu_v12_0_get_enabled_mask(struct smu_context *smu, - uint32_t *feature_mask, uint32_t num) -{ - uint32_t feature_mask_high = 0, feature_mask_low = 0; - int ret = 0; - - if (!feature_mask || num < 2) - return -EINVAL; - - ret = smu_send_smc_msg(smu, SMU_MSG_GetEnabledSmuFeaturesHigh, &feature_mask_high); - if (ret) - return ret; - - ret = smu_send_smc_msg(smu, SMU_MSG_GetEnabledSmuFeaturesLow, &feature_mask_low); - if (ret) - return ret; - - feature_mask[0] = feature_mask_low; - feature_mask[1] = feature_mask_high; - - return ret; -} - int smu_v12_0_mode2_reset(struct smu_context *smu){ return smu_v12_0_send_msg_with_param(smu, SMU_MSG_GfxDeviceDriverReset, SMU_RESET_MODE_2, NULL); } |