diff options
author | Gerd Knorr <devnull@localhost> | 2004-10-15 10:29:24 +0000 |
---|---|---|
committer | Gerd Knorr <devnull@localhost> | 2004-10-15 10:29:24 +0000 |
commit | 3aab516671baf08a091ff7e0afae63539929998e (patch) | |
tree | a0b97af77444436fb8759245d04f286aeede34b6 | |
parent | 5e6d195c487cfb4e5fe4076405d22024afcb1788 (diff) | |
download | mediapointer-dvb-s2-3aab516671baf08a091ff7e0afae63539929998e.tar.gz mediapointer-dvb-s2-3aab516671baf08a091ff7e0afae63539929998e.tar.bz2 |
- fix cx88 polling.
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-video.c | 23 | ||||
-rw-r--r-- | linux/drivers/media/video/msp3400-driver.c | 2 | ||||
-rw-r--r-- | linux/drivers/media/video/msp3400.c | 2 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-tvaudio.c | 11 | ||||
-rw-r--r-- | v4l/scripts/update | 3 |
5 files changed, 33 insertions, 8 deletions
diff --git a/linux/drivers/media/video/cx88/cx88-video.c b/linux/drivers/media/video/cx88/cx88-video.c index 8d3dc06ba..31137f14e 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.41 2004/10/13 10:39:00 kraxel Exp $ + * $Id: cx88-video.c,v 1.42 2004/10/15 10:29:24 kraxel Exp $ * * device driver for Conexant 2388x based TV cards * video4linux video interface @@ -1032,7 +1032,8 @@ static unsigned int video_poll(struct file *file, struct poll_table_struct *wait) { struct cx8800_fh *fh = file->private_data; - + struct cx88_buffer *buf; + if (V4L2_BUF_TYPE_VBI_CAPTURE == fh->type) { if (!res_get(fh->dev,fh,RESOURCE_VBI)) return POLLERR; @@ -1040,8 +1041,22 @@ video_poll(struct file *file, struct poll_table_struct *wait) &fh->vbiq, wait); } - /* FIXME */ - return POLLERR; + if (res_check(fh,RESOURCE_VIDEO)) { + /* streaming capture */ + if (list_empty(&fh->vidq.stream)) + return POLLERR; + buf = list_entry(fh->vidq.stream.next,struct cx88_buffer,vb.stream); + } else { + /* read() capture */ + buf = (struct cx88_buffer*)fh->vidq.read_buf; + if (NULL == buf) + return POLLERR; + } + poll_wait(file, &buf->vb.done, wait); + if (buf->vb.state == STATE_DONE || + buf->vb.state == STATE_ERROR) + return POLLIN|POLLRDNORM; + return 0; } static int video_release(struct inode *inode, struct file *file) diff --git a/linux/drivers/media/video/msp3400-driver.c b/linux/drivers/media/video/msp3400-driver.c index 3e59e05e7..819906100 100644 --- a/linux/drivers/media/video/msp3400-driver.c +++ b/linux/drivers/media/video/msp3400-driver.c @@ -749,7 +749,7 @@ static int msp34xx_sleep(struct msp3400c *msp, int timeout) schedule(); } else { #if 0 - /* hmm, that one doesn't return after waking up msp->wq */ + /* hmm, that one doesn't return on wakeup ... */ msleep_interruptible(timeout); #else set_current_state(TASK_INTERRUPTIBLE); diff --git a/linux/drivers/media/video/msp3400.c b/linux/drivers/media/video/msp3400.c index 3e59e05e7..819906100 100644 --- a/linux/drivers/media/video/msp3400.c +++ b/linux/drivers/media/video/msp3400.c @@ -749,7 +749,7 @@ static int msp34xx_sleep(struct msp3400c *msp, int timeout) schedule(); } else { #if 0 - /* hmm, that one doesn't return after waking up msp->wq */ + /* hmm, that one doesn't return on wakeup ... */ msleep_interruptible(timeout); #else set_current_state(TASK_INTERRUPTIBLE); diff --git a/linux/drivers/media/video/saa7134/saa7134-tvaudio.c b/linux/drivers/media/video/saa7134/saa7134-tvaudio.c index 682c79857..0b911e8d8 100644 --- a/linux/drivers/media/video/saa7134/saa7134-tvaudio.c +++ b/linux/drivers/media/video/saa7134/saa7134-tvaudio.c @@ -1,5 +1,5 @@ /* - * $Id: saa7134-tvaudio.c,v 1.14 2004/10/13 10:39:00 kraxel Exp $ + * $Id: saa7134-tvaudio.c,v 1.15 2004/10/15 10:29:24 kraxel Exp $ * * device driver for philips saa7134 based TV cards * tv audio decoder (fm stereo, nicam, ...) @@ -330,8 +330,15 @@ static int tvaudio_sleep(struct saa7134_dev *dev, int timeout) if (timeout < 0) { set_current_state(TASK_INTERRUPTIBLE); schedule(); - } else + } else { +#if 0 + /* hmm, that one doesn't return on wakeup ... */ msleep_interruptible(timeout); +#else + set_current_state(TASK_INTERRUPTIBLE); + schedule_timeout(msecs_to_jiffies(timeout)); +#endif + } } remove_wait_queue(&dev->thread.wq, &wait); return dev->thread.scan1 != dev->thread.scan2; diff --git a/v4l/scripts/update b/v4l/scripts/update index 920cdbd48..c4529e238 100644 --- a/v4l/scripts/update +++ b/v4l/scripts/update @@ -58,6 +58,9 @@ sync; sleep 1; v4l2basic #xrmmod video-buf #xinsmod video-buf debug=2 +#xrmmod v4l1-compat +#xinsmod v4l1-compat debug=1 + xinsmod btcx-risc debug=0 xinsmod ir-common debug=0 repeat=0 xinsmod tuner debug=0 |