MLK-16353-1 Revert "MLK-16255-6 video: fbdev: dcss: use aligned width to calc pitch...
authorFancy Fang <chen.fang@nxp.com>
Fri, 1 Sep 2017 08:03:15 +0000 (16:03 +0800)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 20:38:27 +0000 (15:38 -0500)
Previously, the alignment issue was handled by allocating
aligned buffer and doing cropping in DCSS. But the VPU IP
doesn't support aligned buffer allocation. So revert this
patch and later use another workaround in DTRC to handle
the alignment issue.

This reverts commit e850fdbafe188e6be6d3219d86bb14271c7cd787.

drivers/video/fbdev/mxc/imx_dcss.c

index 005df68..ffd4c8f 100644 (file)
@@ -1516,8 +1516,9 @@ static int dcss_dpr_config(uint32_t dpr_ch, struct dcss_info *info)
                return -EINVAL;
        }
 
+       /* TODO: calculate pitch for different formats */
        /* config pitch */
-       pitch = (num_pix_x * (var->bits_per_pixel >> 3)) << 16;
+       pitch = (var->xres * (var->bits_per_pixel >> 3)) << 16;
        fill_sb(cb, chan_info->dpr_addr + 0x70, pitch);
 
        fill_sb(cb, chan_info->dpr_addr + 0x200, 0x38);