Commit 9485af4e authored by Alvin Lee's avatar Alvin Lee Committed by Alex Deucher

drm/amd/display: Only flush inst_fb if backdoor loading

[Why]
DAL resume from BACO time is longer if we always flush inst_fb

[How]
Check if backdoor loading to flush inst_fb
Signed-off-by: default avatarAlvin Lee <alvin.lee2@amd.com>
Reviewed-by: default avatarNicholas Kazlauskas <Nicholas.Kazlauskas@amd.com>
Acked-by: default avatarEryk Brol <eryk.brol@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 480c5b8f
...@@ -418,17 +418,18 @@ enum dmub_status dmub_srv_hw_init(struct dmub_srv *dmub, ...@@ -418,17 +418,18 @@ enum dmub_status dmub_srv_hw_init(struct dmub_srv *dmub,
cw1.region.base = DMUB_CW1_BASE; cw1.region.base = DMUB_CW1_BASE;
cw1.region.top = cw1.region.base + stack_fb->size - 1; cw1.region.top = cw1.region.base + stack_fb->size - 1;
if (params->load_inst_const && dmub->hw_funcs.backdoor_load) {
/** /**
* Read back all the instruction memory so we don't hang the * Read back all the instruction memory so we don't hang the
* DMCUB when backdoor loading if the write from x86 hasn't been * DMCUB when backdoor loading if the write from x86 hasn't been
* flushed yet. This only occurs in backdoor loading. * flushed yet. This only occurs in backdoor loading.
*/ */
dmub_flush_buffer_mem(inst_fb); dmub_flush_buffer_mem(inst_fb);
if (params->load_inst_const && dmub->hw_funcs.backdoor_load)
dmub->hw_funcs.backdoor_load(dmub, &cw0, &cw1); dmub->hw_funcs.backdoor_load(dmub, &cw0, &cw1);
} }
}
if (dmub->hw_funcs.reset) if (dmub->hw_funcs.reset)
dmub->hw_funcs.reset(dmub); dmub->hw_funcs.reset(dmub);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment