Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

atm: simplify lanai.c by using module_pci_driver

This simplifies the lanai.c driver by using
the module_pci_driver() macro, at the expense
of losing only debugging messages.

Signed-off-by: Michael Opdenacker <michael.opdenacker@free-electrons.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Michael Opdenacker and committed by
David S. Miller
b7983e3f 2c6ba4b1

+1 -21
+1 -21
drivers/atm/lanai.c
··· 2614 2614 .probe = lanai_init_one, 2615 2615 }; 2616 2616 2617 - static int __init lanai_module_init(void) 2618 - { 2619 - int x; 2620 - 2621 - x = pci_register_driver(&lanai_driver); 2622 - if (x != 0) 2623 - printk(KERN_ERR DEV_LABEL ": no adapter found\n"); 2624 - return x; 2625 - } 2626 - 2627 - static void __exit lanai_module_exit(void) 2628 - { 2629 - /* We'll only get called when all the interfaces are already 2630 - * gone, so there isn't much to do 2631 - */ 2632 - DPRINTK("cleanup_module()\n"); 2633 - pci_unregister_driver(&lanai_driver); 2634 - } 2635 - 2636 - module_init(lanai_module_init); 2637 - module_exit(lanai_module_exit); 2617 + module_pci_driver(lanai_driver); 2638 2618 2639 2619 MODULE_AUTHOR("Mitchell Blank Jr <mitch@sfgoth.com>"); 2640 2620 MODULE_DESCRIPTION("Efficient Networks Speedstream 3010 driver");