Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b6f57210 authored by Peter Hüwe's avatar Peter Hüwe Committed by David S. Miller
Browse files

net/ethernet/toshiba/tc35815: Use module_pci_driver to register driver



Removing some boilerplate by using module_pci_driver instead of calling
register and unregister in the otherwise empty init/exit functions.

Signed-off-by: default avatarPeter Huewe <peterhuewe@gmx.de>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 31d60ebf
Loading
Loading
Loading
Loading
+1 −13
Original line number Diff line number Diff line
@@ -2209,18 +2209,6 @@ MODULE_PARM_DESC(speed, "0:auto, 10:10Mbps, 100:100Mbps");
module_param_named(duplex, options.duplex, int, 0);
MODULE_PARM_DESC(duplex, "0:auto, 1:half, 2:full");

static int __init tc35815_init_module(void)
{
	return pci_register_driver(&tc35815_pci_driver);
}

static void __exit tc35815_cleanup_module(void)
{
	pci_unregister_driver(&tc35815_pci_driver);
}

module_init(tc35815_init_module);
module_exit(tc35815_cleanup_module);

module_pci_driver(tc35815_pci_driver);
MODULE_DESCRIPTION("TOSHIBA TC35815 PCI 10M/100M Ethernet driver");
MODULE_LICENSE("GPL");