drm/amd/display: fix global sync param extraction indexing
authorDmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Fri, 23 Aug 2019 18:22:40 +0000 (14:22 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 17 Sep 2019 13:06:54 +0000 (08:06 -0500)
dcn20_calculate_dlg_params was incorrectly indexing pipe src and
dst structs when extracting global sync params.

Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Reviewed-by: Jaehyun Chung <Jaehyun.Chung@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/dcn20/dcn20_resource.c

index 0fab223..9335dca 100644 (file)
@@ -2640,8 +2640,8 @@ void dcn20_calculate_dlg_params(
                        continue;
 
                if (!visited[pipe_idx]) {
-                       display_pipe_source_params_st *src = &pipes[pipe_idx_unsplit].pipe.src;
-                       display_pipe_dest_params_st *dst = &pipes[pipe_idx_unsplit].pipe.dest;
+                       display_pipe_source_params_st *src = &pipes[pipe_idx].pipe.src;
+                       display_pipe_dest_params_st *dst = &pipes[pipe_idx].pipe.dest;
 
                        dst->vstartup_start = context->bw_ctx.dml.vba.VStartup[pipe_idx_unsplit];
                        dst->vupdate_offset = context->bw_ctx.dml.vba.VUpdateOffsetPix[pipe_idx_unsplit];