diff options
author | Michael Hunold <devnull@localhost> | 2003-02-27 14:37:07 +0000 |
---|---|---|
committer | Michael Hunold <devnull@localhost> | 2003-02-27 14:37:07 +0000 |
commit | eedc7fd38fcda5ad3f241225580db5189faae05a (patch) | |
tree | 33a6d3de2d7123dfcdea9388bbb2ac1919079bbf /linux | |
parent | b8852a2112a64e58ed0a6a0b513e55eeceeb75ca (diff) | |
download | mediapointer-dvb-s2-eedc7fd38fcda5ad3f241225580db5189faae05a.tar.gz mediapointer-dvb-s2-eedc7fd38fcda5ad3f241225580db5189faae05a.tar.bz2 |
- fix some bugs that appeared in system with both analog and digital
based saa7146 cards
- change the initialization order to allow static builds of the mxb driver
Diffstat (limited to 'linux')
-rw-r--r-- | linux/drivers/media/common/saa7146_core.c | 13 | ||||
-rw-r--r-- | linux/drivers/media/common/saa7146_fops.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/dvb/dvb-core/dvb_frontend.c | 2 | ||||
-rw-r--r-- | linux/drivers/media/video/mxb.c | 7 | ||||
-rw-r--r-- | linux/drivers/media/video/tea6420.c | 2 |
5 files changed, 18 insertions, 10 deletions
diff --git a/linux/drivers/media/common/saa7146_core.c b/linux/drivers/media/common/saa7146_core.c index 7e8f9c87c..aa01dd78f 100644 --- a/linux/drivers/media/common/saa7146_core.c +++ b/linux/drivers/media/common/saa7146_core.c @@ -28,9 +28,9 @@ struct list_head saa7146_devices; struct semaphore saa7146_devices_lock; static int initialized = 0; -static int saa7146_num = 0; +int saa7146_num = 0; -unsigned int saa7146_debug = 0; +unsigned int saa7146_debug = 247; MODULE_PARM(saa7146_debug,"i"); MODULE_PARM_DESC(saa7146_debug, "debug level (default: 0)"); @@ -311,10 +311,6 @@ int __devinit saa7146_init_one(struct pci_dev *pci, const struct pci_device_id * init_MUTEX(&dev->i2c_lock); - INIT_LIST_HEAD(&dev->item); - list_add_tail(&dev->item,&saa7146_devices); - saa7146_num++; - dev->module = THIS_MODULE; init_waitqueue_head(&dev->i2c_wq); @@ -331,6 +327,11 @@ int __devinit saa7146_init_one(struct pci_dev *pci, const struct pci_device_id * err = -ENODEV; goto attach_error; } + + INIT_LIST_HEAD(&dev->item); + list_add_tail(&dev->item,&saa7146_devices); + saa7146_num++; + err = 0; goto out; attach_error: diff --git a/linux/drivers/media/common/saa7146_fops.c b/linux/drivers/media/common/saa7146_fops.c index 217b85f14..9048bc339 100644 --- a/linux/drivers/media/common/saa7146_fops.c +++ b/linux/drivers/media/common/saa7146_fops.c @@ -193,14 +193,14 @@ int fops_open(struct inode *inode, struct file *file) dev = h; } } - DEB_D(("using: %p\n",dev)); - if (NULL == dev) { DEB_S(("no such video device.\n")); result = -ENODEV; goto out; } + DEB_D(("using: %p\n",dev)); + /* check if an extension is registered */ if( NULL == dev->ext ) { DEB_S(("no extension registered for this device.\n")); diff --git a/linux/drivers/media/dvb/dvb-core/dvb_frontend.c b/linux/drivers/media/dvb/dvb-core/dvb_frontend.c index dadb9d933..7f63e26cd 100644 --- a/linux/drivers/media/dvb/dvb-core/dvb_frontend.c +++ b/linux/drivers/media/dvb/dvb-core/dvb_frontend.c @@ -435,7 +435,7 @@ int dvb_frontend_thread (void *data) dprintk ("%s\n", __FUNCTION__); lock_kernel (); -#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,63)) +#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,61)) daemonize (); #else daemonize ("dvb fe"); diff --git a/linux/drivers/media/video/mxb.c b/linux/drivers/media/video/mxb.c index b7e459371..ae3b5a7c3 100644 --- a/linux/drivers/media/video/mxb.c +++ b/linux/drivers/media/video/mxb.c @@ -206,6 +206,12 @@ static int mxb_probe(struct saa7146_dev* dev) struct mxb* mxb = 0; int i = 0; + request_module("tuner"); + request_module("tea6420"); + request_module("tea6415c"); + request_module("tda9840"); + request_module("saa7111"); + mxb = (struct mxb*)kmalloc(sizeof(struct mxb), GFP_KERNEL); if( NULL == mxb ) { DEB_D(("not enough kernel memory.\n")); @@ -243,6 +249,7 @@ static int mxb_probe(struct saa7146_dev* dev) /* check if all devices are present */ if( 0 == mxb->tea6420_1 || 0 == mxb->tea6420_2 || 0 == mxb->tea6415c || 0 == mxb->tda9840 || 0 == mxb->saa7111a || 0 == mxb->tuner ) { + printk("mxb: did not find all i2c devices. are you sure you\n"); printk("mxb: insmod'ed tea6420, tea6415c, saa7111, tea6415c and tuner?\n"); i2c_del_adapter(&mxb->i2c_adapter); diff --git a/linux/drivers/media/video/tea6420.c b/linux/drivers/media/video/tea6420.c index d860d1002..3d8bf1e18 100644 --- a/linux/drivers/media/video/tea6420.c +++ b/linux/drivers/media/video/tea6420.c @@ -1,5 +1,5 @@ /* - tea6420.h - i2c-driver for the tea6420 by SGS Thomson + tea6420.o - i2c-driver for the tea6420 by SGS Thomson Copyright (C) 1998-2003 Michael Hunold <michael@mihu.de> |