summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
authorBhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>2017-10-03 13:53:51 -0400
committerAlex Deucher <alexander.deucher@amd.com>2017-10-21 16:49:02 -0400
commit80e80ec817f161560b4159608fb41bd289abede3 (patch)
tree7f704a207cf9d1f62b14fa05aa9355c111bb5e7f /drivers/gpu/drm
parent2938bbb646107d4e39bf850a5bc09385abd012e8 (diff)
drm/amd/display: Fix underscan not using proper scaling
fix underscan not being set correctly Signed-off-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com> Reviewed-by: Harry Wentland <Harry.Wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/amd/display/dc/core/dc.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c
index 4df5bf750257..12aeb6d83f42 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc.c
@@ -1362,7 +1362,7 @@ void dc_commit_updates_for_stream(struct dc *dc,
enum surface_update_type update_type;
struct dc_state *context;
struct dc_context *dc_ctx = dc->ctx;
- int i;
+ int i, j;
stream_status = dc_stream_get_status(stream);
context = dc->current_state;
@@ -1396,8 +1396,17 @@ void dc_commit_updates_for_stream(struct dc *dc,
if (srf_updates[i].flip_addr)
surface->address = srf_updates[i].flip_addr->address;
- }
+ if (update_type >= UPDATE_TYPE_MED) {
+ for (j = 0; j < dc->res_pool->pipe_count; j++) {
+ struct pipe_ctx *pipe_ctx = &context->res_ctx.pipe_ctx[j];
+
+ if (pipe_ctx->plane_state != surface)
+ continue;
+ resource_build_scaling_params(pipe_ctx);
+ }
+ }
+ }
commit_planes_for_stream(
dc,