Skip to content

Commit 34dc227

Browse files
Kenneth Fengalexdeucher
authored andcommitted
drm/amd/pm: add power save mode workload for smu 13.0.10
add power save mode workload for smu 13.0.10, so that in compute mode, pmfw will add margin since some applications requres higher margin. Signed-off-by: Kenneth Feng <kenneth.feng@amd.com> Reviewed-by: Likun Gao <Likun.Gao@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 5f82a0c commit 34dc227

1 file changed

Lines changed: 13 additions & 10 deletions

File tree

drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2545,16 +2545,19 @@ static int smu_v13_0_0_set_power_profile_mode(struct smu_context *smu,
25452545

25462546
workload_mask = 1 << workload_type;
25472547

2548-
/* Add optimizations for SMU13.0.0. Reuse the power saving profile */
2549-
if (smu->power_profile_mode == PP_SMC_POWER_PROFILE_COMPUTE &&
2550-
(amdgpu_ip_version(smu->adev, MP1_HWIP, 0) == IP_VERSION(13, 0, 0)) &&
2551-
((smu->adev->pm.fw_version == 0x004e6601) ||
2552-
(smu->adev->pm.fw_version >= 0x004e7400))) {
2553-
workload_type = smu_cmn_to_asic_specific_index(smu,
2554-
CMN2ASIC_MAPPING_WORKLOAD,
2555-
PP_SMC_POWER_PROFILE_POWERSAVING);
2556-
if (workload_type >= 0)
2557-
workload_mask |= 1 << workload_type;
2548+
/* Add optimizations for SMU13.0.0/10. Reuse the power saving profile */
2549+
if (smu->power_profile_mode == PP_SMC_POWER_PROFILE_COMPUTE) {
2550+
if ((amdgpu_ip_version(smu->adev, MP1_HWIP, 0) == IP_VERSION(13, 0, 0) &&
2551+
((smu->adev->pm.fw_version == 0x004e6601) ||
2552+
(smu->adev->pm.fw_version >= 0x004e7300))) ||
2553+
(amdgpu_ip_version(smu->adev, MP1_HWIP, 0) == IP_VERSION(13, 0, 10) &&
2554+
smu->adev->pm.fw_version >= 0x00504500)) {
2555+
workload_type = smu_cmn_to_asic_specific_index(smu,
2556+
CMN2ASIC_MAPPING_WORKLOAD,
2557+
PP_SMC_POWER_PROFILE_POWERSAVING);
2558+
if (workload_type >= 0)
2559+
workload_mask |= 1 << workload_type;
2560+
}
25582561
}
25592562

25602563
return smu_cmn_send_smc_msg_with_param(smu,

0 commit comments

Comments
 (0)