drm/amd/display: Fixed 4K black issue by refactor update surface.
Signed-off-by: Yongqiang Sun <yongqiang.sun@amd.com> Reviewed-by: Tony Cheng <Tony.Cheng@amd.com> Acked-by: Harry Wentland <Harry.Wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
committed by
Alex Deucher
parent
86e2e1bee0
commit
ed15194032
@@ -1482,6 +1482,7 @@ void dc_update_surfaces_for_stream(struct dc *dc,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* not sure if we still need this */
|
/* not sure if we still need this */
|
||||||
|
if (update_type == UPDATE_TYPE_FULL) {
|
||||||
for (j = 0; j < context->res_ctx.pool->pipe_count; j++) {
|
for (j = 0; j < context->res_ctx.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];
|
||||||
struct core_stream *stream = pipe_ctx->stream;
|
struct core_stream *stream = pipe_ctx->stream;
|
||||||
@@ -1495,6 +1496,7 @@ void dc_update_surfaces_for_stream(struct dc *dc,
|
|||||||
pipe_ctx->scl_data.recout.width -= 2;
|
pipe_ctx->scl_data.recout.width -= 2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (dc->debug.disable_color_module)
|
if (dc->debug.disable_color_module)
|
||||||
continue; /* skip below color updates */
|
continue; /* skip below color updates */
|
||||||
@@ -1563,10 +1565,12 @@ void dc_update_surfaces_for_stream(struct dc *dc,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (update_type == UPDATE_TYPE_FULL) {
|
if (update_type == UPDATE_TYPE_FULL) {
|
||||||
core_dc->hwss.apply_ctx_for_surface(core_dc, surface, context);
|
/* only apply for top pipe */
|
||||||
} else if (updates[i].flip_addr) {
|
if (!pipe_ctx->top_pipe)
|
||||||
|
core_dc->hwss.apply_ctx_for_surface(core_dc,
|
||||||
|
surface, context);
|
||||||
|
} else if (updates[i].flip_addr)
|
||||||
core_dc->hwss.update_plane_addr(core_dc, pipe_ctx);
|
core_dc->hwss.update_plane_addr(core_dc, pipe_ctx);
|
||||||
}
|
|
||||||
|
|
||||||
if (update_type == UPDATE_TYPE_FAST)
|
if (update_type == UPDATE_TYPE_FAST)
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
Reference in New Issue
Block a user