drm/amd/pm: modify the fine grain tuning function for vangogh
authorXiaojian Du <Xiaojian.Du@amd.com>
Wed, 13 Jan 2021 10:46:43 +0000 (18:46 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 14 Jan 2021 18:13:38 +0000 (13:13 -0500)
commitd7379efae6ac2cdb27f7cfeeedb29c468d2a9faa
tree49d73ec6993fcb976fd77c9afc2fbc3406f976d9
parente017fb66f7ac152009a41810023e23b7bb6debf7
drm/amd/pm: modify the fine grain tuning function for vangogh

This patch is to modify the fine grain tuning function for vangogh.
This patch uses the existing old flag to make the two sysfs files
work separately -- "power_dpm_force_performance_level" and
"pp_od_clk_voltage".
Only the power_dpm_force_performance_level is switched to "manual"
mode, the fine grain tuning function will be started.
In other mode, including "high","low","min_sclk","min_mclk",
"standard" and "peak", the fine grain tuning function will be shut down,
and the frequency range of gfx and cpu clock will be restored the
default values.

Signed-off-by: Xiaojian Du <Xiaojian.Du@amd.com>
Reviewed-by: Kevin Wang <kevin1.wang@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
drivers/gpu/drm/amd/pm/swsmu/smu11/vangogh_ppt.c