The patch number 14084 was added via Douglas Schilling Landgraf <dougsl...@redhat.com> to http://linuxtv.org/hg/v4l-dvb master development tree.
Kernel patches in this development tree may be modified to be backward compatible with older kernels. Compatibility modifications will be removed before inclusion into the mainstream Kernel If anyone has any objections, please let us know by sending a message to: Linux Media Mailing List <linux-me...@vger.kernel.org> ------ From: Jean Delvare <kh...@linux-fr.org> dvb/bt8xx: Clean-up init and exit functions The init and exit functions are needlessly complex. Remove the bloat: * Drop irrelevant/outdated comments. * Remove useless bt878_pci_driver_registered global variable. Priority: normal Signed-off-by: Jean Delvare <kh...@linux-fr.org> Signed-off-by: Mauro Carvalho chehab <mche...@redhat.com> Signed-off-by: Douglas Schilling Landgraf <dougsl...@redhat.com> --- linux/drivers/media/dvb/bt8xx/bt878.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff -r 8bf74a0eb35d -r 2bff2afa8261 linux/drivers/media/dvb/bt8xx/bt878.c --- a/linux/drivers/media/dvb/bt8xx/bt878.c Mon Feb 01 15:36:08 2010 -0200 +++ b/linux/drivers/media/dvb/bt8xx/bt878.c Mon Feb 01 15:37:53 2010 -0200 @@ -580,8 +580,6 @@ .remove = __devexit_p(bt878_remove), }; -static int bt878_pci_driver_registered; - /*******************************/ /* Module management functions */ /*******************************/ @@ -589,34 +587,23 @@ static int __init bt878_init_module(void) { bt878_num = 0; - bt878_pci_driver_registered = 0; printk(KERN_INFO "bt878: AUDIO driver version %d.%d.%d loaded\n", (BT878_VERSION_CODE >> 16) & 0xff, (BT878_VERSION_CODE >> 8) & 0xff, BT878_VERSION_CODE & 0xff); -/* - bt878_check_chipset(); -*/ - /* later we register inside of bt878_find_audio_dma() - * because we may want to ignore certain cards */ - bt878_pci_driver_registered = 1; + return pci_register_driver(&bt878_pci_driver); } static void __exit bt878_cleanup_module(void) { - if (bt878_pci_driver_registered) { - bt878_pci_driver_registered = 0; - pci_unregister_driver(&bt878_pci_driver); - } - return; + pci_unregister_driver(&bt878_pci_driver); } module_init(bt878_init_module); module_exit(bt878_cleanup_module); -//MODULE_AUTHOR("XXX"); MODULE_LICENSE("GPL"); /* --- Patch is available at: http://linuxtv.org/hg/v4l-dvb/rev/2bff2afa8261e63a09a0c5f2c239262e958b67cb _______________________________________________ linuxtv-commits mailing list linuxtv-commits@linuxtv.org http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits