summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGerd Knorr <devnull@localhost>2005-02-03 10:24:33 +0000
committerGerd Knorr <devnull@localhost>2005-02-03 10:24:33 +0000
commit71daf2d7061f7fd30d949da8071621d6d7f83b6e (patch)
tree049da215fa6494bbe5868a3f2482870b3b50fb9f
parenta32182686d2a324b78fea725bc25cdb333e6366c (diff)
downloadmediapointer-dvb-s2-71daf2d7061f7fd30d949da8071621d6d7f83b6e.tar.gz
mediapointer-dvb-s2-71daf2d7061f7fd30d949da8071621d6d7f83b6e.tar.bz2
- saa7134 ts fixes by Eric Lammerts + /me.
-rw-r--r--linux/drivers/media/video/saa7134/saa7134-empress.c10
-rw-r--r--linux/drivers/media/video/saa7134/saa7134-ts.c6
-rw-r--r--linux/drivers/media/video/saa7134/saa7134-video.c6
3 files changed, 12 insertions, 10 deletions
diff --git a/linux/drivers/media/video/saa7134/saa7134-empress.c b/linux/drivers/media/video/saa7134/saa7134-empress.c
index a7c38745b..4bce95289 100644
--- a/linux/drivers/media/video/saa7134/saa7134-empress.c
+++ b/linux/drivers/media/video/saa7134/saa7134-empress.c
@@ -1,5 +1,5 @@
/*
- * $Id: saa7134-empress.c,v 1.9 2004/12/10 12:33:39 kraxel Exp $
+ * $Id: saa7134-empress.c,v 1.10 2005/02/03 10:24:33 kraxel Exp $
*
* (c) 2004 Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]
*
@@ -96,17 +96,19 @@ static int ts_open(struct inode *inode, struct file *file)
return -ENODEV;
dprintk("open minor=%d\n",minor);
- down(&dev->empress_tsq.lock);
err = -EBUSY;
- if (dev->empress_users)
+ if (down_trylock(&dev->empress_tsq.lock))
goto done;
+ if (dev->empress_users)
+ goto done_up;
dev->empress_users++;
file->private_data = dev;
err = 0;
- done:
+done_up:
up(&dev->empress_tsq.lock);
+done:
return err;
}
diff --git a/linux/drivers/media/video/saa7134/saa7134-ts.c b/linux/drivers/media/video/saa7134/saa7134-ts.c
index 888e15c96..345eb2a8c 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.13 2004/12/10 12:33:39 kraxel Exp $
+ * $Id: saa7134-ts.c,v 1.14 2005/02/03 10:24:33 kraxel Exp $
*
* device driver for philips saa7134 based TV cards
* video4linux video interface
@@ -221,10 +221,10 @@ void saa7134_irq_ts_done(struct saa7134_dev *dev, unsigned long status)
if (dev->ts_q.curr) {
field = dev->ts_q.curr->vb.field;
if (field == V4L2_FIELD_TOP) {
- if ((status & 0x100000) != 0x100000)
+ if ((status & 0x100000) != 0x000000)
goto done;
} else {
- if ((status & 0x100000) != 0x000000)
+ if ((status & 0x100000) != 0x100000)
goto done;
}
saa7134_buffer_finish(dev,&dev->ts_q,STATE_DONE);
diff --git a/linux/drivers/media/video/saa7134/saa7134-video.c b/linux/drivers/media/video/saa7134/saa7134-video.c
index b313709c7..eb485fc9f 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.25 2004/12/10 12:33:39 kraxel Exp $
+ * $Id: saa7134-video.c,v 1.26 2005/02/03 10:24:33 kraxel Exp $
*
* device driver for philips saa7134 based TV cards
* video4linux video interface
@@ -2365,10 +2365,10 @@ void saa7134_irq_video_done(struct saa7134_dev *dev, unsigned long status)
if (!dev->video_q.curr->top_seen)
goto done;
} else if (field == V4L2_FIELD_TOP) {
- if ((status & 0x10) != 0x10)
+ if ((status & 0x10) != 0x00)
goto done;
} else if (field == V4L2_FIELD_BOTTOM) {
- if ((status & 0x10) != 0x00)
+ if ((status & 0x10) != 0x10)
goto done;
}
dev->video_q.curr->vb.field_count = dev->video_fieldcount;