mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-01 01:14:19 -04:00
drm/amd/display: Temporary workaround to toggle watermark setting
[Why] Watermarks not propagated to DCHUBP after it is powered on [How] Add temoprary function apply_DEDCN21_147_wa to apply wm settings for Renoir Signed-off-by: Lewis Huang <Lewis.Huang@amd.com> Reviewed-by: Tony Cheng <Tony.Cheng@amd.com> Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com> Reviewed-by: Roman Li <Roman.Li@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
committed by
Alex Deucher
parent
d4516d3ec5
commit
f93e29f083
@@ -1533,6 +1533,10 @@ static void dcn20_program_front_end_for_ctx(
|
||||
msleep(1);
|
||||
}
|
||||
}
|
||||
|
||||
/* WA to apply WM setting*/
|
||||
if (dc->hwseq->wa.DEGVIDCN21)
|
||||
dc->res_pool->hubbub->funcs->apply_DEDCN21_147_wa(dc->res_pool->hubbub);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -616,6 +616,14 @@ void hubbub21_wm_read_state(struct hubbub *hubbub,
|
||||
DCHUBBUB_ARB_ALLOW_DRAM_CLK_CHANGE_WATERMARK_D, &s->dram_clk_chanage);
|
||||
}
|
||||
|
||||
void hubbub21_apply_DEDCN21_147_wa(struct hubbub *hubbub)
|
||||
{
|
||||
struct dcn20_hubbub *hubbub1 = TO_DCN20_HUBBUB(hubbub);
|
||||
uint32_t prog_wm_value;
|
||||
|
||||
prog_wm_value = REG_READ(DCHUBBUB_ARB_DATA_URGENCY_WATERMARK_A);
|
||||
REG_WRITE(DCHUBBUB_ARB_DATA_URGENCY_WATERMARK_A, prog_wm_value);
|
||||
}
|
||||
|
||||
static const struct hubbub_funcs hubbub21_funcs = {
|
||||
.update_dchub = hubbub2_update_dchub,
|
||||
@@ -627,6 +635,7 @@ static const struct hubbub_funcs hubbub21_funcs = {
|
||||
.wm_read_state = hubbub21_wm_read_state,
|
||||
.get_dchub_ref_freq = hubbub2_get_dchub_ref_freq,
|
||||
.program_watermarks = hubbub21_program_watermarks,
|
||||
.apply_DEDCN21_147_wa = hubbub21_apply_DEDCN21_147_wa,
|
||||
};
|
||||
|
||||
void hubbub21_construct(struct dcn20_hubbub *hubbub,
|
||||
|
||||
@@ -1470,6 +1470,7 @@ static struct dce_hwseq *dcn21_hwseq_create(
|
||||
hws->regs = &hwseq_reg;
|
||||
hws->shifts = &hwseq_shift;
|
||||
hws->masks = &hwseq_mask;
|
||||
hws->wa.DEGVIDCN21 = true;
|
||||
}
|
||||
return hws;
|
||||
}
|
||||
|
||||
@@ -147,6 +147,7 @@ struct hubbub_funcs {
|
||||
bool (*is_allow_self_refresh_enabled)(struct hubbub *hubbub);
|
||||
void (*allow_self_refresh_control)(struct hubbub *hubbub, bool allow);
|
||||
|
||||
void (*apply_DEDCN21_147_wa)(struct hubbub *hubbub);
|
||||
};
|
||||
|
||||
struct hubbub {
|
||||
|
||||
Reference in New Issue
Block a user