Commit cbd975d0 authored by Aric Cyr's avatar Aric Cyr Committed by Alex Deucher

drm/amd/display: Revert check for flip pending before locking pipes

Signed-off-by: default avatarAric Cyr <aric.cyr@amd.com>
Acked-by: default avatarRodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent ec30798a
...@@ -2384,6 +2384,7 @@ static void commit_planes_for_stream(struct dc *dc, ...@@ -2384,6 +2384,7 @@ static void commit_planes_for_stream(struct dc *dc,
enum surface_update_type update_type, enum surface_update_type update_type,
struct dc_state *context) struct dc_state *context)
{ {
bool mpcc_disconnected = false;
int i, j; int i, j;
struct pipe_ctx *top_pipe_to_program = NULL; struct pipe_ctx *top_pipe_to_program = NULL;
...@@ -2414,8 +2415,14 @@ static void commit_planes_for_stream(struct dc *dc, ...@@ -2414,8 +2415,14 @@ static void commit_planes_for_stream(struct dc *dc,
context_clock_trace(dc, context); context_clock_trace(dc, context);
} }
if (update_type != UPDATE_TYPE_FAST && dc->hwss.interdependent_update_lock && dc->hwss.wait_for_pending_cleared) if (update_type != UPDATE_TYPE_FAST && dc->hwss.interdependent_update_lock &&
dc->hwss.disconnect_pipes(dc, context); dc->hwss.disconnect_pipes && dc->hwss.wait_for_pending_cleared){
dc->hwss.interdependent_update_lock(dc, context, true);
mpcc_disconnected = dc->hwss.disconnect_pipes(dc, context);
dc->hwss.interdependent_update_lock(dc, context, false);
if (mpcc_disconnected)
dc->hwss.wait_for_pending_cleared(dc, context);
}
for (j = 0; j < dc->res_pool->pipe_count; j++) { for (j = 0; j < dc->res_pool->pipe_count; j++) {
struct pipe_ctx *pipe_ctx = &context->res_ctx.pipe_ctx[j]; struct pipe_ctx *pipe_ctx = &context->res_ctx.pipe_ctx[j];
......
...@@ -2761,7 +2761,7 @@ static struct pipe_ctx *dcn10_find_top_pipe_for_stream( ...@@ -2761,7 +2761,7 @@ static struct pipe_ctx *dcn10_find_top_pipe_for_stream(
return NULL; return NULL;
} }
void dcn10_disconnect_pipes( bool dcn10_disconnect_pipes(
struct dc *dc, struct dc *dc,
struct dc_state *context) struct dc_state *context)
{ {
...@@ -2772,10 +2772,6 @@ void dcn10_disconnect_pipes( ...@@ -2772,10 +2772,6 @@ void dcn10_disconnect_pipes(
bool mpcc_disconnected = false; bool mpcc_disconnected = false;
struct pipe_ctx *old_pipe; struct pipe_ctx *old_pipe;
struct pipe_ctx *new_pipe; struct pipe_ctx *new_pipe;
dc->hwss.wait_for_pending_cleared(dc, context);
dc->hwss.interdependent_update_lock(dc, context, true);
DC_LOGGER_INIT(dc->ctx->logger); DC_LOGGER_INIT(dc->ctx->logger);
/* Set pipe update flags and lock pipes */ /* Set pipe update flags and lock pipes */
...@@ -2878,11 +2874,7 @@ void dcn10_disconnect_pipes( ...@@ -2878,11 +2874,7 @@ void dcn10_disconnect_pipes(
} }
} }
} }
return mpcc_disconnected;
dc->hwss.interdependent_update_lock(dc, context, false);
if (mpcc_disconnected)
dc->hwss.wait_for_pending_cleared(dc, context);
} }
void dcn10_wait_for_pending_cleared(struct dc *dc, void dcn10_wait_for_pending_cleared(struct dc *dc,
......
...@@ -194,7 +194,7 @@ void dcn10_get_surface_visual_confirm_color( ...@@ -194,7 +194,7 @@ void dcn10_get_surface_visual_confirm_color(
void dcn10_get_hdr_visual_confirm_color( void dcn10_get_hdr_visual_confirm_color(
struct pipe_ctx *pipe_ctx, struct pipe_ctx *pipe_ctx,
struct tg_color *color); struct tg_color *color);
void dcn10_disconnect_pipes( bool dcn10_disconnect_pipes(
struct dc *dc, struct dc *dc,
struct dc_state *context); struct dc_state *context);
......
...@@ -67,7 +67,7 @@ struct hw_sequencer_funcs { ...@@ -67,7 +67,7 @@ struct hw_sequencer_funcs {
int num_planes, struct dc_state *context); int num_planes, struct dc_state *context);
void (*program_front_end_for_ctx)(struct dc *dc, void (*program_front_end_for_ctx)(struct dc *dc,
struct dc_state *context); struct dc_state *context);
void (*disconnect_pipes)(struct dc *dc, bool (*disconnect_pipes)(struct dc *dc,
struct dc_state *context); struct dc_state *context);
void (*wait_for_pending_cleared)(struct dc *dc, void (*wait_for_pending_cleared)(struct dc *dc,
struct dc_state *context); struct dc_state *context);
......
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