Skip to content

Commit 0844881

Browse files
Nicholas Kazlauskasalexdeucher
authored andcommitted
drm/amd/display: Remove min_dst_y_next_start check for Z8
[Why] Flickering occurs on DRR supported panels when engaged in DRR due to min_dst_y_next becoming larger than the frame size itself. [How] In general, we should be able to enter Z8 when this is engaged but it might be a net power loss even if the calculation wasn't bugged. Don't support enabling Z8 during the DRR region. Cc: [email protected] # 6.1+ Reviewed-by: Syed Hassan <[email protected]> Acked-by: Hamza Mahfooz <[email protected]> Signed-off-by: Nicholas Kazlauskas <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
1 parent 6b0b778 commit 0844881

File tree

1 file changed

+1
-14
lines changed

1 file changed

+1
-14
lines changed

drivers/gpu/drm/amd/display/dc/dml/dcn20/dcn20_fpu.c

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -950,10 +950,8 @@ static enum dcn_zstate_support_state decide_zstate_support(struct dc *dc, struc
950950
{
951951
int plane_count;
952952
int i;
953-
unsigned int min_dst_y_next_start_us;
954953

955954
plane_count = 0;
956-
min_dst_y_next_start_us = 0;
957955
for (i = 0; i < dc->res_pool->pipe_count; i++) {
958956
if (context->res_ctx.pipe_ctx[i].plane_state)
959957
plane_count++;
@@ -975,26 +973,15 @@ static enum dcn_zstate_support_state decide_zstate_support(struct dc *dc, struc
975973
else if (context->stream_count == 1 && context->streams[0]->signal == SIGNAL_TYPE_EDP) {
976974
struct dc_link *link = context->streams[0]->sink->link;
977975
struct dc_stream_status *stream_status = &context->stream_status[0];
978-
struct dc_stream_state *current_stream = context->streams[0];
979976
int minmum_z8_residency = dc->debug.minimum_z8_residency_time > 0 ? dc->debug.minimum_z8_residency_time : 1000;
980977
bool allow_z8 = context->bw_ctx.dml.vba.StutterPeriod > (double)minmum_z8_residency;
981978
bool is_pwrseq0 = link->link_index == 0;
982-
bool isFreesyncVideo;
983-
984-
isFreesyncVideo = current_stream->adjust.v_total_min == current_stream->adjust.v_total_max;
985-
isFreesyncVideo = isFreesyncVideo && current_stream->timing.v_total < current_stream->adjust.v_total_min;
986-
for (i = 0; i < dc->res_pool->pipe_count; i++) {
987-
if (context->res_ctx.pipe_ctx[i].stream == current_stream && isFreesyncVideo) {
988-
min_dst_y_next_start_us = context->res_ctx.pipe_ctx[i].dlg_regs.min_dst_y_next_start_us;
989-
break;
990-
}
991-
}
992979

993980
/* Don't support multi-plane configurations */
994981
if (stream_status->plane_count > 1)
995982
return DCN_ZSTATE_SUPPORT_DISALLOW;
996983

997-
if (is_pwrseq0 && (context->bw_ctx.dml.vba.StutterPeriod > 5000.0 || min_dst_y_next_start_us > 5000))
984+
if (is_pwrseq0 && context->bw_ctx.dml.vba.StutterPeriod > 5000.0)
998985
return DCN_ZSTATE_SUPPORT_ALLOW;
999986
else if (is_pwrseq0 && link->psr_settings.psr_version == DC_PSR_VERSION_1 && !link->panel_config.psr.disable_psr)
1000987
return allow_z8 ? DCN_ZSTATE_SUPPORT_ALLOW_Z8_Z10_ONLY : DCN_ZSTATE_SUPPORT_ALLOW_Z10_ONLY;

0 commit comments

Comments
 (0)