Signed-off-by: Hyun Kwon <hyun.kwon@xxxxxxxxxx> --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/xlnx/zynqmp_disp.c b/drivers/gpu/drm/xlnx/zynqmp_disp.c index d2e1034..fd6ddfe 100644 --- a/drivers/gpu/drm/xlnx/zynqmp_disp.c +++ b/drivers/gpu/drm/xlnx/zynqmp_disp.c @@ -2138,6 +2138,7 @@ static int zynqmp_disp_plane_mode_set(struct drm_plane *plane, for (i = 0; i < info->num_planes; i++) { unsigned int width = src_w / (i ? info->hsub : 1); unsigned int height = src_h / (i ? info->vsub : 1); + int width_bytes; paddr = drm_fb_cma_get_gem_addr(fb, plane->state, i); if (!paddr) { @@ -2146,7 +2147,8 @@ static int zynqmp_disp_plane_mode_set(struct drm_plane *plane, } layer->dma[i].xt.numf = height; - layer->dma[i].sgl[0].size = width * info->cpp[i]; + width_bytes = drm_format_plane_width_bytes(info, i, width); + layer->dma[i].sgl[0].size = width_bytes; layer->dma[i].sgl[0].icg = fb->pitches[i] - layer->dma[i].sgl[0].size; layer->dma[i].xt.src_start = paddr; -- 2.7.4 _______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/dri-devel