Commit c84f5123 authored by Bhawanpreet Lakha's avatar Bhawanpreet Lakha Committed by Alex Deucher

drm/amd/display: Add Replay supported/enabled checks

- Add checks for Cursor update and dirty rects (sending updates to dmub)
- Add checks for dc_notify_vsync, and fbc and subvp
Signed-off-by: default avatarBhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Reviewed-by: default avatarHarry Wentland <harry.wentland@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent a8b273a8
...@@ -3289,6 +3289,9 @@ static bool dc_dmub_should_send_dirty_rect_cmd(struct dc *dc, struct dc_stream_s ...@@ -3289,6 +3289,9 @@ static bool dc_dmub_should_send_dirty_rect_cmd(struct dc *dc, struct dc_stream_s
&& stream->ctx->dce_version >= DCN_VERSION_3_1) && stream->ctx->dce_version >= DCN_VERSION_3_1)
return true; return true;
if (stream->link->replay_settings.config.replay_supported)
return true;
return false; return false;
} }
...@@ -5173,6 +5176,9 @@ void dc_notify_vsync_int_state(struct dc *dc, struct dc_stream_state *stream, bo ...@@ -5173,6 +5176,9 @@ void dc_notify_vsync_int_state(struct dc *dc, struct dc_stream_state *stream, bo
if (link->psr_settings.psr_feature_enabled) if (link->psr_settings.psr_feature_enabled)
return; return;
if (link->replay_settings.replay_feature_enabled)
return;
/*find primary pipe associated with stream*/ /*find primary pipe associated with stream*/
for (i = 0; i < MAX_PIPES; i++) { for (i = 0; i < MAX_PIPES; i++) {
pipe = &dc->current_state->res_ctx.pipe_ctx[i]; pipe = &dc->current_state->res_ctx.pipe_ctx[i];
......
...@@ -897,6 +897,9 @@ static bool dc_dmub_should_update_cursor_data(struct pipe_ctx *pipe_ctx) ...@@ -897,6 +897,9 @@ static bool dc_dmub_should_update_cursor_data(struct pipe_ctx *pipe_ctx)
pipe_ctx->stream->ctx->dce_version >= DCN_VERSION_3_1) pipe_ctx->stream->ctx->dce_version >= DCN_VERSION_3_1)
return true; return true;
if (pipe_ctx->stream->link->replay_settings.config.replay_supported)
return true;
return false; return false;
} }
......
...@@ -1590,6 +1590,7 @@ static enum dc_status apply_single_controller_ctx_to_hw( ...@@ -1590,6 +1590,7 @@ static enum dc_status apply_single_controller_ctx_to_hw(
*/ */
if (pipe_ctx->stream->mall_stream_config.type != SUBVP_PHANTOM) { if (pipe_ctx->stream->mall_stream_config.type != SUBVP_PHANTOM) {
pipe_ctx->stream->link->psr_settings.psr_feature_enabled = false; pipe_ctx->stream->link->psr_settings.psr_feature_enabled = false;
pipe_ctx->stream->link->replay_settings.replay_feature_enabled = false;
} }
return DC_OK; return DC_OK;
} }
...@@ -2021,6 +2022,10 @@ static bool should_enable_fbc(struct dc *dc, ...@@ -2021,6 +2022,10 @@ static bool should_enable_fbc(struct dc *dc,
if (pipe_ctx->stream->link->psr_settings.psr_feature_enabled) if (pipe_ctx->stream->link->psr_settings.psr_feature_enabled)
return false; return false;
/* Replay should not be enabled */
if (pipe_ctx->stream->link->replay_settings.replay_feature_enabled)
return false;
/* Nothing to compress */ /* Nothing to compress */
if (!pipe_ctx->plane_state) if (!pipe_ctx->plane_state)
return false; return false;
......
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