summaryrefslogtreecommitdiff
path: root/linux/drivers/media/common/saa7146_vbi.c
diff options
context:
space:
mode:
authorMichael Hunold <devnull@localhost>2003-12-15 20:54:10 +0000
committerMichael Hunold <devnull@localhost>2003-12-15 20:54:10 +0000
commit8ee8836220158e91941b7d508b5179bd49c5944d (patch)
tree56181f889a882e6da2c0558e5a26911905149bbf /linux/drivers/media/common/saa7146_vbi.c
parentb12f792f25aafd619d357cd987fd6682ee405e11 (diff)
downloadmediapointer-dvb-s2-8ee8836220158e91941b7d508b5179bd49c5944d.tar.gz
mediapointer-dvb-s2-8ee8836220158e91941b7d508b5179bd49c5944d.tar.bz2
- fix compilation
- more video/vbi open/release fixes
Diffstat (limited to 'linux/drivers/media/common/saa7146_vbi.c')
-rw-r--r--linux/drivers/media/common/saa7146_vbi.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/linux/drivers/media/common/saa7146_vbi.c b/linux/drivers/media/common/saa7146_vbi.c
index f9a815cc8..da9332f97 100644
--- a/linux/drivers/media/common/saa7146_vbi.c
+++ b/linux/drivers/media/common/saa7146_vbi.c
@@ -310,7 +310,7 @@ static struct videobuf_queue_ops vbi_qops = {
/* ------------------------------------------------------------------ */
-static void vbi_stop(struct saa7146_fh *fh)
+static void vbi_stop(struct saa7146_fh *fh, struct file *file)
{
struct saa7146_dev *dev = fh->dev;
struct saa7146_vv *vv = dev->vv_data;
@@ -344,12 +344,13 @@ static void vbi_stop(struct saa7146_fh *fh)
static void vbi_read_timeout(unsigned long data)
{
- struct saa7146_fh *fh = (struct saa7146_fh *)data;
+ struct file *file = (struct file*)data;
+ struct saa7146_fh *fh = file->private_data;
struct saa7146_dev *dev = fh->dev;
DEB_VBI(("dev:%p, fh:%p\n",dev, fh));
- vbi_stop(fh);
+ vbi_stop(fh, file);
}
static void vbi_init(struct saa7146_dev *dev, struct saa7146_vv *vv)
@@ -366,8 +367,10 @@ static void vbi_init(struct saa7146_dev *dev, struct saa7146_vv *vv)
init_waitqueue_head(&vv->vbi_wq);
}
-static void vbi_open(struct saa7146_dev *dev, struct saa7146_fh *fh)
+static void vbi_open(struct saa7146_dev *dev, struct file *file)
{
+ struct saa7146_fh *fh = (struct saa7146_fh *)file->private_data;
+
u32 arbtr_ctrl = saa7146_read(dev, PCI_BT_V1);
int ret = 0;
@@ -401,7 +404,7 @@ static void vbi_open(struct saa7146_dev *dev, struct saa7146_fh *fh)
init_timer(&fh->vbi_read_timeout);
fh->vbi_read_timeout.function = vbi_read_timeout;
- fh->vbi_read_timeout.data = (unsigned long)fh;
+ fh->vbi_read_timeout.data = (unsigned long)file;
/* initialize the brs */
if ( 0 != (SAA7146_USE_PORT_B_FOR_VBI & dev->ext_vv_data->flags)) {
@@ -419,14 +422,14 @@ static void vbi_open(struct saa7146_dev *dev, struct saa7146_fh *fh)
saa7146_write(dev, MC2, (MASK_08|MASK_24));
}
-static void vbi_close(struct saa7146_dev *dev, struct saa7146_fh *fh, struct file *file)
+static void vbi_close(struct saa7146_dev *dev, struct file *file)
{
+ struct saa7146_fh *fh = (struct saa7146_fh *)file->private_data;
struct saa7146_vv *vv = dev->vv_data;
- unsigned long flags;
DEB_VBI(("dev:%p, fh:%p\n",dev,fh));
if( fh == vv->vbi_streaming ) {
- vbi_stop(fh);
+ vbi_stop(fh, file);
}
}