blob: ddbd6cfca405cdf23c64dbb2f813ea78ab8ff7f5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
From 576e50bcf58410331419d06391546d2fed183f13 Mon Sep 17 00:00:00 2001
From: Andrew Jiang <Andrew.Jiang@amd.com>
Date: Tue, 10 Oct 2017 14:36:39 -0400
Subject: [PATCH 2588/4131] drm/amd/display: Correct timings in build scaling
params
A previous patch set the addressable timing as active + border,
when in fact, the VESA standard specifies active as equal to
addressable + border.
This patch makes the fix more correct and in line with the standard.
Signed-off-by: Andrew Jiang <Andrew.Jiang@amd.com>
Reviewed-by: Andrew Jiang <Andrew.Jiang@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Harry Wentland <Harry.Wentland@amd.com>
---
drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 17 +++--------------
1 file changed, 3 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
index 55feb16..0aca7a3 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
@@ -850,22 +850,11 @@ bool resource_build_scaling_params(struct pipe_ctx *pipe_ctx)
*/
pipe_ctx->plane_res.scl_data.lb_params.depth = LB_PIXEL_DEPTH_30BPP;
- /**
- * KMD sends us h and v_addressable without the borders, which causes us sometimes to draw
- * the blank region on-screen. Correct for this by adding the borders back to their
- * respective addressable values, and by shifting recout.
- */
- timing->h_addressable += timing->h_border_left + timing->h_border_right;
- timing->v_addressable += timing->v_border_top + timing->v_border_bottom;
- pipe_ctx->plane_res.scl_data.recout.y += timing->v_border_top;
pipe_ctx->plane_res.scl_data.recout.x += timing->h_border_left;
- timing->v_border_top = 0;
- timing->v_border_bottom = 0;
- timing->h_border_left = 0;
- timing->h_border_right = 0;
+ pipe_ctx->plane_res.scl_data.recout.y += timing->v_border_top;
- pipe_ctx->plane_res.scl_data.h_active = timing->h_addressable;
- pipe_ctx->plane_res.scl_data.v_active = timing->v_addressable;
+ pipe_ctx->plane_res.scl_data.h_active = timing->h_addressable + timing->h_border_left + timing->h_border_right;
+ pipe_ctx->plane_res.scl_data.v_active = timing->v_addressable + timing->v_border_top + timing->v_border_bottom;
/* Taps calculations */
if (pipe_ctx->plane_res.xfm != NULL)
--
2.7.4
|