drm/amd/display: fix dce_calc surface pitch setting for non underlay pipes
authorDmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Wed, 29 Mar 2017 20:24:19 +0000 (16:24 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 26 Sep 2017 21:22:03 +0000 (17:22 -0400)
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Acked-by: Harry Wentland <Harry.Wentland@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/calcs/dce_calcs.c

index 5ac614f433f8d219c2a71c6e07bf3faa697d4277..627b7582394a2de5788e3adaf961401bb8fa3953 100644 (file)
@@ -2614,7 +2614,7 @@ static void populate_initial_data(
                data->v_total[num_displays + 4] = bw_int_to_fixed(pipe[i].stream->public.timing.v_total);
                data->pixel_rate[num_displays + 4] = bw_frc_to_fixed(pipe[i].stream->public.timing.pix_clk_khz, 1000);
                data->src_width[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.viewport.width);
-               data->pitch_in_pixels[num_displays + 4] = bw_int_to_fixed(pipe[i].surface->public.plane_size.grph.surface_pitch);
+               data->pitch_in_pixels[num_displays + 4] = data->src_width[num_displays + 4];
                data->src_height[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.viewport.height);
                data->h_taps[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.taps.h_taps);
                data->v_taps[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.taps.v_taps);
@@ -2712,7 +2712,7 @@ static void populate_initial_data(
                data->pixel_rate[num_displays + 4] = bw_frc_to_fixed(pipe[i].stream->public.timing.pix_clk_khz, 1000);
                if (pipe[i].surface) {
                        data->src_width[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.viewport.width);
-                       data->pitch_in_pixels[num_displays + 4] = bw_int_to_fixed(pipe[i].surface->public.plane_size.grph.surface_pitch);
+                       data->pitch_in_pixels[num_displays + 4] = data->src_width[num_displays + 4];
                        data->src_height[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.viewport.height);
                        data->h_taps[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.taps.h_taps);
                        data->v_taps[num_displays + 4] = bw_int_to_fixed(pipe[i].scl_data.taps.v_taps);