lkml.org 
[lkml]   [2008]   [Jan]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [v4l-dvb-maintainer] [PATCH] Re: Regression: VIDIOCGMBUF ioctl hangs on bttv driver (2.6.24-rc6)
Hi guys,

Gregor, we have converted bttv driver to use vidioc_ioctl2 some days ago.
Could you check and create your patch against v4l development tree?
Bttv driver does not have anymore bttv_do_ioctl().

Cheers,
Douglas

On Jan 6, 2008 12:15 PM, Gregor Jasny <jasny@vidsoft.de> wrote:
> From: Gregor Jasny <gjasny@web.de>
>
> Fix bttv VIDIOCGMBUF locking like done in commit
> 820eacd84cff23b76693f4be1e28feb672f4488f.
>
> Signed-off-by: Gregor Jasny <gjasny@web.de>
> ---
> diff --git a/drivers/media/video/bt8xx/bttv-driver.c b/drivers/media/video/bt8xx/bttv-driver.c
> index c02d92d..581a3c9 100644
> --- a/drivers/media/video/bt8xx/bttv-driver.c
> +++ b/drivers/media/video/bt8xx/bttv-driver.c
> @@ -3063,11 +3063,10 @@ static int bttv_do_ioctl(struct inode *inode, struct file *file,
> struct video_mbuf *mbuf = arg;
> unsigned int i;
>
> - mutex_lock(&fh->cap.lock);
> retval = videobuf_mmap_setup(&fh->cap,gbuffers,gbufsize,
> V4L2_MEMORY_MMAP);
> if (retval < 0)
> - goto fh_unlock_and_return;
> + return retval;
>
> gbuffers = retval;
> memset(mbuf,0,sizeof(*mbuf));
> @@ -3075,7 +3074,6 @@ static int bttv_do_ioctl(struct inode *inode, struct file *file,
> mbuf->size = gbuffers * gbufsize;
> for (i = 0; i < gbuffers; i++)
> mbuf->offsets[i] = i * gbufsize;
> - mutex_unlock(&fh->cap.lock);
> return 0;
> }
> case VIDIOCMCAPTURE:
>
>
> _______________________________________________
> v4l-dvb-maintainer mailing list
> v4l-dvb-maintainer@linuxtv.org
> http://www.linuxtv.org/cgi-bin/mailman/listinfo/v4l-dvb-maintainer
>


\
 
 \ /
  Last update: 2008-01-06 23:55    [W:0.906 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site