drm/amd/pm: handling of set performance level

display performance level when set not supported

Signed-off-by: Mangesh Gadre <Mangesh.Gadre@amd.com>
Reviewed-by: Lijo Lazar <lijo.lazar@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Mangesh Gadre 2025-02-21 17:38:21 +08:00 committed by Alex Deucher
parent 9424a5bf08
commit 700e535db4
2 changed files with 7 additions and 2 deletions

View File

@ -2315,7 +2315,12 @@ static int smu_adjust_power_state_dynamic(struct smu_context *smu,
if (smu_dpm_ctx->dpm_level != level) {
ret = smu_asic_set_performance_level(smu, level);
if (ret) {
dev_err(smu->adev->dev, "Failed to set performance level!");
if (ret == -EOPNOTSUPP)
dev_info(smu->adev->dev, "set performance level %d not supported",
level);
else
dev_err(smu->adev->dev, "Failed to set performance level %d",
level);
return ret;
}

View File

@ -1940,7 +1940,7 @@ static int smu_v13_0_6_set_performance_level(struct smu_context *smu,
break;
}
return -EINVAL;
return -EOPNOTSUPP;
}
static int smu_v13_0_6_set_soft_freq_limited_range(struct smu_context *smu,