Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

sun4i_csi: Fixes kernel bug during camera init, v4l field must be set…

… from camera driver response

Just a one line patch that fixes the camera initialization on the
tablets.  I realize the rest of the driver code from allwinner is ugly
as sin, I'll try and submit a style patch later.

Signed-off-by: Neal Peacock <neal@nic-stix.com>
  • Loading branch information...
commit ba52c95134e5befe16f2eb1cca418cc0fd32512e 1 parent a4c351f
@npeacock npeacock authored amery committed
Showing with 2 additions and 1 deletion.
  1. +2 −1  drivers/media/video/sun4i_csi/csi0/sun4i_drv_csi.c
View
3  drivers/media/video/sun4i_csi/csi0/sun4i_drv_csi.c
@@ -807,7 +807,7 @@ static int vidioc_try_fmt_vid_cap(struct file *file, void *priv,
struct csi_fmt *csi_fmt;
struct v4l2_mbus_framefmt ccm_fmt;//linux-3.0
int ret = 0;
-
+
csi_dbg(0,"vidioc_try_fmt_vid_cap\n");
/*judge the resolution*/
@@ -838,6 +838,7 @@ static int vidioc_try_fmt_vid_cap(struct file *file, void *priv,
f->fmt.pix.height = ccm_fmt.height;//linux-3.0
// f->fmt.pix.bytesperline = ccm_fmt.fmt.pix.bytesperline;//linux-3.0
// f->fmt.pix.sizeimage = ccm_fmt.fmt.pix.sizeimage;//linux-3.0
+ f->fmt.pix.field = ccm_fmt.field; /* Needed even if none */
csi_dbg(0,"pix->width=%d\n",f->fmt.pix.width);
csi_dbg(0,"pix->height=%d\n",f->fmt.pix.height);
Please sign in to comment.
Something went wrong with that request. Please try again.