drm/amd/pp: Fix bug voltage can't be OD separately on VI
Make sure to update the MCLK and SCLK flags when setting the VDDC flags due to dependencies. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
d78fd72558
commit
84f8508f71
1 changed files with 10 additions and 6 deletions
|
@ -4743,23 +4743,27 @@ static void smu7_check_dpm_table_updated(struct pp_hwmgr *hwmgr)
|
||||||
|
|
||||||
for (i=0; i < dep_table->count; i++) {
|
for (i=0; i < dep_table->count; i++) {
|
||||||
if (dep_table->entries[i].vddc != odn_dep_table->entries[i].vddc) {
|
if (dep_table->entries[i].vddc != odn_dep_table->entries[i].vddc) {
|
||||||
data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_VDDC;
|
data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_VDDC | DPMTABLE_OD_UPDATE_MCLK;
|
||||||
break;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (i == dep_table->count)
|
if (i == dep_table->count && data->need_update_smu7_dpm_table & DPMTABLE_OD_UPDATE_VDDC) {
|
||||||
data->need_update_smu7_dpm_table &= ~DPMTABLE_OD_UPDATE_VDDC;
|
data->need_update_smu7_dpm_table &= ~DPMTABLE_OD_UPDATE_VDDC;
|
||||||
|
data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_MCLK;
|
||||||
|
}
|
||||||
|
|
||||||
dep_table = table_info->vdd_dep_on_sclk;
|
dep_table = table_info->vdd_dep_on_sclk;
|
||||||
odn_dep_table = (struct phm_ppt_v1_clock_voltage_dependency_table *)&(odn_table->vdd_dependency_on_sclk);
|
odn_dep_table = (struct phm_ppt_v1_clock_voltage_dependency_table *)&(odn_table->vdd_dependency_on_sclk);
|
||||||
for (i=0; i < dep_table->count; i++) {
|
for (i=0; i < dep_table->count; i++) {
|
||||||
if (dep_table->entries[i].vddc != odn_dep_table->entries[i].vddc) {
|
if (dep_table->entries[i].vddc != odn_dep_table->entries[i].vddc) {
|
||||||
data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_VDDC;
|
data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_VDDC | DPMTABLE_OD_UPDATE_SCLK;
|
||||||
break;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (i == dep_table->count)
|
if (i == dep_table->count && data->need_update_smu7_dpm_table & DPMTABLE_OD_UPDATE_VDDC) {
|
||||||
data->need_update_smu7_dpm_table &= ~DPMTABLE_OD_UPDATE_VDDC;
|
data->need_update_smu7_dpm_table &= ~DPMTABLE_OD_UPDATE_VDDC;
|
||||||
|
data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_SCLK;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static int smu7_odn_edit_dpm_table(struct pp_hwmgr *hwmgr,
|
static int smu7_odn_edit_dpm_table(struct pp_hwmgr *hwmgr,
|
||||||
|
|
Loading…
Reference in a new issue