diff options
author | Trent Piepho <xyzzy@speakeasy.org> | 2009-01-12 08:09:46 -0800 |
---|---|---|
committer | Trent Piepho <xyzzy@speakeasy.org> | 2009-01-12 08:09:46 -0800 |
commit | e57810fd54e2f3f93bab0027078435fa5ce6fa9b (patch) | |
tree | 54d4653f75bed31e6d77903bc244f5d8833a4bfe /linux/drivers/media | |
parent | 60514cdd01298455a98066edd16a562ee2750ce7 (diff) | |
download | mediapointer-dvb-s2-e57810fd54e2f3f93bab0027078435fa5ce6fa9b.tar.gz mediapointer-dvb-s2-e57810fd54e2f3f93bab0027078435fa5ce6fa9b.tar.bz2 |
fixup previous patch
From: Trent Piepho <xyzzy@speakeasy.org>
Commited patch 0a97a636c31e wasn't the latest version of the patch. This
fixes some problems with it and should be folded into it.
Priority: normal
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Diffstat (limited to 'linux/drivers/media')
-rw-r--r-- | linux/drivers/media/video/zoran/zoran_card.c | 31 |
1 files changed, 8 insertions, 23 deletions
diff --git a/linux/drivers/media/video/zoran/zoran_card.c b/linux/drivers/media/video/zoran/zoran_card.c index 925737e8f..fbac547d0 100644 --- a/linux/drivers/media/video/zoran/zoran_card.c +++ b/linux/drivers/media/video/zoran/zoran_card.c @@ -1278,7 +1278,10 @@ static int __devinit zoran_probe(struct pci_dev *pdev, nr = atomic_inc_return(&zoran_num) - 1; if (nr >= BUZ_MAX) { - dev_err(&pdev->dev, "driver limited to %d card(s) maximum\n", BUZ_MAX); + dprintk(1, + KERN_ERR + "%s: driver limited to %d card(s) maximum\n", + ZORAN_NAME, BUZ_MAX); return -ENOENT; } @@ -1565,29 +1568,21 @@ static int __devinit zoran_probe(struct pci_dev *pdev, return 0; - /* Init errors */ zr_detach_vfe: videocodec_detach(zr->vfe); - zr_free_vfe: kfree(master_vfe); - zr_detach_codec: videocodec_detach(zr->codec); - zr_free_codec: kfree(master_codec); - zr_unreg_i2c: zoran_unregister_i2c(zr); - zr_free_irq: btwrite(0, ZR36057_SPGPPCR); free_irq(zr->pci_dev->irq, zr); - zr_unmap: iounmap(zr->zr36057_mem); - zr_free_mem: kfree(zr); @@ -1603,7 +1598,7 @@ static struct pci_driver zoran_driver = { static int __init zoran_init(void) { - int i; + int res; memset(zoran, 0, sizeof(zoran)); printk(KERN_INFO "Zoran MJPEG board driver version %d.%d.%d\n", @@ -1650,13 +1645,13 @@ static int __init zoran_init(void) ZORAN_NAME); } - i = pci_register_driver(&zoran_driver); - if (i) { + res = pci_register_driver(&zoran_driver); + if (res) { dprintk(1, KERN_ERR "%s: Unable to register ZR36057 driver\n", ZORAN_NAME); - return i; + return res; } return 0; @@ -1669,13 +1664,3 @@ static void __exit zoran_exit(void) module_init(zoran_init); module_exit(zoran_exit); - -/* -todo: - use pci ioremap functions - - use id table to provide card type - - get rid of zoran[] array -*/ - |