diff options
author | Gerd Knorr <devnull@localhost> | 2004-10-11 14:53:12 +0000 |
---|---|---|
committer | Gerd Knorr <devnull@localhost> | 2004-10-11 14:53:12 +0000 |
commit | 3de5a0bda8a7e0289857223e3b645c0782aee2b7 (patch) | |
tree | e8d872427c5bcf1f84d7c88a8510f6d08e24e4a9 /linux/drivers/media/video | |
parent | 10a75fb37fbb1ab822371d834328d87a8409ff23 (diff) | |
download | mediapointer-dvb-s2-3de5a0bda8a7e0289857223e3b645c0782aee2b7.tar.gz mediapointer-dvb-s2-3de5a0bda8a7e0289857223e3b645c0782aee2b7.tar.bz2 |
- fix poll/select oops.
Diffstat (limited to 'linux/drivers/media/video')
-rw-r--r-- | linux/drivers/media/video/bttv-driver.c | 7 | ||||
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-blackbird.c | 5 | ||||
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-video.c | 10 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-ts.c | 5 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-video.c | 5 | ||||
-rw-r--r-- | linux/drivers/media/video/video-buf.c | 7 |
6 files changed, 24 insertions, 15 deletions
diff --git a/linux/drivers/media/video/bttv-driver.c b/linux/drivers/media/video/bttv-driver.c index f432cad03..57a54b0ba 100644 --- a/linux/drivers/media/video/bttv-driver.c +++ b/linux/drivers/media/video/bttv-driver.c @@ -1,6 +1,6 @@ /* - $Id: bttv-driver.c,v 1.20 2004/10/11 13:45:51 kraxel Exp $ + $Id: bttv-driver.c,v 1.21 2004/10/11 14:53:12 kraxel Exp $ bttv - Bt848 frame grabber driver @@ -2873,8 +2873,9 @@ static unsigned int bttv_poll(struct file *file, poll_table *wait) if (V4L2_BUF_TYPE_VBI_CAPTURE == fh->type) { if (!check_alloc_btres(fh->btv,fh,RESOURCE_VBI)) - return -EBUSY; - return videobuf_poll_stream(file->private_data, &fh->vbi, wait); + return POLLERR; + return videobuf_poll_stream(file, file->private_data, + &fh->vbi, wait); } if (check_btres(fh,RESOURCE_VIDEO)) { diff --git a/linux/drivers/media/video/cx88/cx88-blackbird.c b/linux/drivers/media/video/cx88/cx88-blackbird.c index e23284cb3..c85172170 100644 --- a/linux/drivers/media/video/cx88/cx88-blackbird.c +++ b/linux/drivers/media/video/cx88/cx88-blackbird.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-blackbird.c,v 1.12 2004/10/07 12:29:56 kraxel Exp $ + * $Id: cx88-blackbird.c,v 1.13 2004/10/11 14:53:13 kraxel Exp $ * * Support for a cx23416 mpeg encoder via cx2388x host port. * "blackbird" reference design. @@ -734,7 +734,8 @@ mpeg_poll(struct file *file, struct poll_table_struct *wait) { struct cx8802_fh *fh = file->private_data; - return videobuf_poll_stream(file->private_data, &fh->mpegq, wait); + return videobuf_poll_stream(file, file->private_data, + &fh->mpegq, wait); } static int diff --git a/linux/drivers/media/video/cx88/cx88-video.c b/linux/drivers/media/video/cx88/cx88-video.c index 14d2cb074..eeccdb29b 100644 --- a/linux/drivers/media/video/cx88/cx88-video.c +++ b/linux/drivers/media/video/cx88/cx88-video.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-video.c,v 1.38 2004/10/11 13:45:51 kraxel Exp $ + * $Id: cx88-video.c,v 1.39 2004/10/11 14:53:13 kraxel Exp $ * * device driver for Conexant 2388x based TV cards * video4linux video interface @@ -1033,8 +1033,12 @@ video_poll(struct file *file, struct poll_table_struct *wait) { struct cx8800_fh *fh = file->private_data; - if (V4L2_BUF_TYPE_VBI_CAPTURE == fh->type) - return videobuf_poll_stream(file->private_data, &fh->vbiq, wait); + if (V4L2_BUF_TYPE_VBI_CAPTURE == fh->type) { + if (!res_get(fh->dev,fh,RESOURCE_VBI)) + return POLLERR; + return videobuf_poll_stream(file, file->private_data, + &fh->vbiq, wait); + } /* FIXME */ return POLLERR; diff --git a/linux/drivers/media/video/saa7134/saa7134-ts.c b/linux/drivers/media/video/saa7134/saa7134-ts.c index 2df96839a..3c36c3cc9 100644 --- a/linux/drivers/media/video/saa7134/saa7134-ts.c +++ b/linux/drivers/media/video/saa7134/saa7134-ts.c @@ -1,5 +1,5 @@ /* - * $Id: saa7134-ts.c,v 1.8 2004/09/23 13:58:19 kraxel Exp $ + * $Id: saa7134-ts.c,v 1.9 2004/10/11 14:53:13 kraxel Exp $ * * device driver for philips saa7134 based TV cards * video4linux video interface @@ -265,7 +265,8 @@ ts_poll(struct file *file, struct poll_table_struct *wait) { struct saa7134_dev *dev = file->private_data; - return videobuf_poll_stream(file->private_data, &dev->ts.ts, wait); + return videobuf_poll_stream(file, file->private_data, + &dev->ts.ts, wait); } diff --git a/linux/drivers/media/video/saa7134/saa7134-video.c b/linux/drivers/media/video/saa7134/saa7134-video.c index 14cfff8d7..4d79c3dc6 100644 --- a/linux/drivers/media/video/saa7134/saa7134-video.c +++ b/linux/drivers/media/video/saa7134/saa7134-video.c @@ -1,5 +1,5 @@ /* - * $Id: saa7134-video.c,v 1.14 2004/09/23 13:58:19 kraxel Exp $ + * $Id: saa7134-video.c,v 1.15 2004/10/11 14:53:13 kraxel Exp $ * * device driver for philips saa7134 based TV cards * video4linux video interface @@ -1294,7 +1294,8 @@ video_poll(struct file *file, struct poll_table_struct *wait) struct videobuf_buffer *buf = NULL; if (V4L2_BUF_TYPE_VBI_CAPTURE == fh->type) - return videobuf_poll_stream(file->private_data, &fh->vbi, wait); + return videobuf_poll_stream(file, file->private_data, + &fh->vbi, wait); if (res_check(fh,RESOURCE_VIDEO)) { if (!list_empty(&fh->cap.stream)) diff --git a/linux/drivers/media/video/video-buf.c b/linux/drivers/media/video/video-buf.c index 0758b1daf..219143d0a 100644 --- a/linux/drivers/media/video/video-buf.c +++ b/linux/drivers/media/video/video-buf.c @@ -1,5 +1,5 @@ /* - * $Id: video-buf.c,v 1.11 2004/09/23 13:58:19 kraxel Exp $ + * $Id: video-buf.c,v 1.12 2004/10/11 14:53:13 kraxel Exp $ * * generic helper functions for video4linux capture buffers, to handle * memory management and PCI DMA. Right now bttv + saa7134 use it. @@ -921,6 +921,7 @@ ssize_t videobuf_read_stream(void *priv, struct videobuf_queue *q, int err, retval; unsigned long flags; + dprintk(2,"%s\n",__FUNCTION__); down(&q->lock); retval = -EBUSY; if (q->streaming) @@ -999,7 +1000,7 @@ ssize_t videobuf_read_stream(void *priv, struct videobuf_queue *q, return retval; } -unsigned int videobuf_poll_stream(void *priv, +unsigned int videobuf_poll_stream(struct file *file, void *priv, struct videobuf_queue *q, poll_table *wait) { @@ -1029,7 +1030,7 @@ unsigned int videobuf_poll_stream(void *priv, rc = POLLERR; if (0 == rc) { - poll_wait(priv, &buf->done, wait); + poll_wait(file, &buf->done, wait); if (buf->state == STATE_DONE || buf->state == STATE_ERROR) rc = POLLIN|POLLRDNORM; |