]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ENGR00236141 csi:Add stride alignment setting from userspace
authorguoyin.chen <guoyin.chen@freescale.com>
Fri, 7 Dec 2012 02:39:57 +0000 (10:39 +0800)
committerLothar Waßmann <LW@KARO-electronics.de>
Fri, 24 May 2013 06:35:48 +0000 (08:35 +0200)
In android, IPU fills the I420 buffer. And GPU shows the buffer to display.
mx6's GPU has 32 Y-stride alignment for I420. The stride alignment will
be passed through by bytesperline. This update is only for
csi->smfc->mem channel.

Signed-off-by: guoyin.chen <guoyin.chen@freescale.com>
(cherry picked from commit 4708dc1999ed4857799100434e4f46f68f4e7c13)

drivers/media/video/mxc/capture/ipu_csi_enc.c

index 2c8d8d01a971da60188bc8932329d035466a15e3..ff90e2b8eff46eddac46df917b9f38a629a33bff 100644 (file)
@@ -171,7 +171,8 @@ static int csi_enc_setup(cam_data *cam)
        err = ipu_init_channel_buffer(cam->ipu, CSI_MEM, IPU_OUTPUT_BUFFER,
                                      pixel_fmt, cam->v2f.fmt.pix.width,
                                      cam->v2f.fmt.pix.height,
-                                     cam->v2f.fmt.pix.width, IPU_ROTATE_NONE,
+                                     cam->v2f.fmt.pix.bytesperline,
+                                     IPU_ROTATE_NONE,
                                      dummy, dummy, 0,
                                      cam->offset.u_offset,
                                      cam->offset.v_offset);