linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Hans Verkuil <hverkuil@xs4all.nl>
Cc: linux-media@vger.kernel.org, Hans Verkuil <hans.verkuil@cisco.com>
Subject: Re: [PATCH 6/6] uvcvideo: Add VIDIOC_[GS]_PRIORITY support
Date: Fri, 23 Nov 2012 13:30:55 +0100	[thread overview]
Message-ID: <1571163.sdKFpUlEDA@avalon> (raw)
In-Reply-To: <201211161507.42201.hverkuil@xs4all.nl>

Hi Hans,

Thank you for the review.

On Friday 16 November 2012 15:07:42 Hans Verkuil wrote:
> On Thu September 27 2012 17:16:20 Laurent Pinchart wrote:
> > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > ---
> > 
> >  drivers/media/usb/uvc/uvc_driver.c |    3 ++
> >  drivers/media/usb/uvc/uvc_v4l2.c   |   45 +++++++++++++++++++++++++++++++
> >  drivers/media/usb/uvc/uvcvideo.h   |    1 +
> >  3 files changed, 49 insertions(+), 0 deletions(-)
> > 
> > diff --git a/drivers/media/usb/uvc/uvc_driver.c
> > b/drivers/media/usb/uvc/uvc_driver.c index ae24f7d..22f14d2 100644
> > --- a/drivers/media/usb/uvc/uvc_driver.c
> > +++ b/drivers/media/usb/uvc/uvc_driver.c

[snip]

> > @@ -1722,6 +1723,8 @@ static int uvc_register_video(struct uvc_device
> > *dev,
> >  	vdev->v4l2_dev = &dev->vdev;
> >  	vdev->fops = &uvc_fops;
> >  	vdev->release = uvc_release;
> > +	vdev->prio = &stream->chain->prio;
> > +	set_bit(V4L2_FL_USE_FH_PRIO, &vdev->flags);
> 
> This set_bit() doesn't do anything as long as you are not using
> video_ioctl2().

The bit also makes v4l2_fh_(add|del)() call v4l2_prio_(open|close)().

> And why aren't you using video_ioctl2()? This is the last driver to do it
> all manually. If you'd switch to video_ioctl2(), then setting this bit would
> be all you had to do.

I have a patch for that, I need to resurect it.

> >  	if (stream->type == V4L2_BUF_TYPE_VIDEO_OUTPUT)
> >  		vdev->vfl_dir = VFL_DIR_TX;
> >  	
> >  	strlcpy(vdev->name, dev->name, sizeof vdev->name);
> > diff --git a/drivers/media/usb/uvc/uvc_v4l2.c
> > b/drivers/media/usb/uvc/uvc_v4l2.c index bf9d073..d6aa402 100644
> > --- a/drivers/media/usb/uvc/uvc_v4l2.c
> > +++ b/drivers/media/usb/uvc/uvc_v4l2.c

[snip]

> This patch is hard to read since I can't see for which ioctls you check the
> prio. Can you regenerate the patch with more context lines? The patch as it
> is will probably not apply reliably due to the same reason.

My bad. I'll resend it.

> In particular, make sure you also check for the UVC-specific ioctls
> (UVCIOC_CTRL_MAP might need this, but I'm not sure about that).

The UVC-specific ioctls are only control operations, they don't require 
priority handling.

-- 
Regards,

Laurent Pinchart


  reply	other threads:[~2012-11-23 12:29 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1348758980-21683-1-git-send-email-laurent.pinchart@ideasonboard.com>
     [not found] ` <1348758980-21683-5-git-send-email-laurent.pinchart@ideasonboard.com>
2012-11-16 14:00   ` [PATCH 4/6] uvcvideo: Set device_caps in VIDIOC_QUERYCAP Hans Verkuil
2012-11-23 12:20     ` Laurent Pinchart
2012-11-23 12:36       ` Hans Verkuil
     [not found] ` <1348758980-21683-7-git-send-email-laurent.pinchart@ideasonboard.com>
2012-11-16 14:07   ` [PATCH 6/6] uvcvideo: Add VIDIOC_[GS]_PRIORITY support Hans Verkuil
2012-11-23 12:30     ` Laurent Pinchart [this message]
2012-11-23 12:32     ` [PATCH v2 " Laurent Pinchart
2012-11-23 12:56       ` Hans Verkuil
2012-11-16 14:09 ` [PATCH 0/6] uvcvideo: V4L2 compliance fixes Hans Verkuil
     [not found] ` <1348758980-21683-2-git-send-email-laurent.pinchart@ideasonboard.com>
2012-12-24 12:27   ` [PATCH 1/6] uvcvideo: Set error_idx properly for extended controls API failures Laurent Pinchart
2012-12-25 11:15     ` Hans Verkuil
2012-12-25 11:23       ` Laurent Pinchart
2012-12-25 11:50         ` Hans Verkuil
2012-12-26 11:33           ` Laurent Pinchart
2012-12-26 14:00             ` Mauro Carvalho Chehab
2012-12-26 17:24               ` Laurent Pinchart
2012-12-27 11:59             ` Hans Verkuil
2012-12-27 12:04               ` Laurent Pinchart
2013-01-07 11:19               ` Hans Verkuil

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1571163.sdKFpUlEDA@avalon \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=hans.verkuil@cisco.com \
    --cc=hverkuil@xs4all.nl \
    --cc=linux-media@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).