-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I'm adding mailing list to CC so people can correct me if I'm wrong.

[email protected] wrote:
> "I want to make tvp5146 capture interface work in 2.6.28-rc6 download from 
> montavista git  . There were some build errors related it"
> 

1. tvp5146 driver is present at drivers/media/video/tvp514x.c
(Please check 2 if it is not)

2. VPFE drivers available in GIT tree is broken! Please do not use
them. There are new drivers present in Kevin's staging tree for
v4l2-capture. you should see this tree when you look-up remote
branches in your git tree i.e. git branch -r

3. New vpfe drivers are building ok, but not working completely, for
me. My modifications is attached in this mail.

Let me know if you have any troubles.

Regards,
Caglar


________________________________________________________________________

diff --git a/drivers/media/video/davinci/vpfe_capture.c
b/drivers/media/video/davinci/vpfe_capture.c
index 32084e2..de242d0 100644
- --- a/drivers/media/video/davinci/vpfe_capture.c
+++ b/drivers/media/video/davinci/vpfe_capture.c
@@ -313,7 +313,7 @@ static int vpfe_config_format(struct channel_obj
*ch)

        vid_ch = &(ch->video);
        common->crop.top = 0;
- -       common->crop.top = 0;
+       common->crop.left = 0;
        /* first get format information from the decoder.
         * if not available, get it from CCDC
         */
@@ -554,6 +554,8 @@ static irqreturn_t vpfe_isr(int irq, void *dev_id)
                                        common->curFrm->state =
VIDEOBUF_DONE;

wake_up_interruptible(&common->curFrm->
                                                              done);
+                                       common->curFrm->size =
common->fmt.fmt.pix.width *
+
common->fmt.fmt.pix.height * 2;
                                        common->curFrm =
common->nextFrm;
                                }
                                /* based on whether the two fields
are stored
@@ -979,8 +981,8 @@ static int vpfe_try_format(struct channel_obj
*channel,

        if ((pixfmt->height == 0) && (pixfmt->field == V4L2_FIELD_NONE))
                pixfmt->height = 1;
- -       else
- -               pixfmt->height = 2;
+       //else
+       //      pixfmt->height = 2;

        pixfmt->bytesperline = ROUND32(pixfmt->width * bpp);
        if (pixfmt->pixelformat == V4L2_PIX_FMT_NV12)
@@ -2072,9 +2074,17 @@ static int vpfe_cropcap(struct file *file,
void *priv,
 {
        struct vpfe_fh *fh = file->private_data;
        struct channel_obj *channel = fh->channel;
- -       struct v4l2_int_device *dec =
- -               channel->decoder[channel->current_decoder];
- -       return vidioc_int_cropcap(dec, crop);
+       //struct v4l2_int_device *dec =
+       //      channel->decoder[channel->current_decoder];
+       struct video_obj *vid_ch = &(channel->video);
+       struct v4l2_fract pa = VPFE_PIXELASPECT_PAL;
+       crop->bounds.top = crop->bounds.left = 0;
+       crop->bounds.width = vid_ch->std_info.activepixels;
+       crop->bounds.height = vid_ch->std_info.activelines;
+       crop->defrect = crop->bounds;
+       crop->pixelaspect = pa;
+       return 0;
+       //return vidioc_int_cropcap(dec, crop);
 }

 static int vpfe_g_crop(struct file *file, void *priv,
@@ -2156,7 +2166,7 @@ static int vpfe_s_crop(struct file *file, void
*priv,
        } else {
                dev_err(vpfe_dev, "Error in S_CROP params\n");
                ret = -EINVAL;
- -               goto out;
+               goto lock_out;
        }
 lock_out:
        mutex_unlock(&common->lock);
@@ -2209,6 +2219,14 @@ out:
        return ret;
 }

+static int vpfe_s_parm(struct file *file, void *priv,
+               struct v4l2_streamparm *a)
+{
+       /* FIXME: Not supported yet */
+       printk("VPFE s_parm is not implemented yet\n");
+       return 0;
+}
+

 /* vpfe capture ioctl operations */
 static const struct v4l2_ioctl_ops vpfe_ioctl_ops = {
@@ -2236,6 +2254,7 @@ static const struct v4l2_ioctl_ops
vpfe_ioctl_ops = {
        .vidioc_g_crop           = vpfe_g_crop,
        .vidioc_s_crop           = vpfe_s_crop,
        .vidioc_default          = vpfe_param_handler,
+       .vidioc_s_parm           = vpfe_s_parm,
 };

 /*     vpfe_probe : This function creates device entries by register

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org

iEYEARECAAYFAkmL+WAACgkQ/nL+S5dojeiTpQCfX6wAfx3277xfTMcACh8WWF84
XMoAn3Dpr/R5va0ek0MkPx7uIrToZOAm
=sb1J
-----END PGP SIGNATURE-----

_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source

Reply via email to