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

Configure Feed

Select the types of activity you want to include in your feed.

net: ethernet: 8390: ne2k-pci: use module_pci_driver() macro

The driver init/exit() function don't do anything special, it
can use the module_pci_driver() macro to eliminate boilerplate
code.

Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Reviewed-by: Pavan Chebbi <pavan.chebbi@broadcom.com>
Link: https://lore.kernel.org/r/20230810014633.3084355-1-yangyingliang@huawei.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Yang Yingliang and committed by
Jakub Kicinski
5604ac35 afa2420c

+1 -15
+1 -15
drivers/net/ethernet/8390/ne2k-pci.c
··· 731 731 .id_table = ne2k_pci_tbl, 732 732 .driver.pm = &ne2k_pci_pm_ops, 733 733 }; 734 - 735 - 736 - static int __init ne2k_pci_init(void) 737 - { 738 - return pci_register_driver(&ne2k_driver); 739 - } 740 - 741 - 742 - static void __exit ne2k_pci_cleanup(void) 743 - { 744 - pci_unregister_driver(&ne2k_driver); 745 - } 746 - 747 - module_init(ne2k_pci_init); 748 - module_exit(ne2k_pci_cleanup); 734 + module_pci_driver(ne2k_driver);