summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/oki-semi/pch_gbe
diff options
context:
space:
mode:
authorPaul Burton <paul.burton@mips.com>2018-06-22 20:17:51 -0700
committerDavid S. Miller <davem@davemloft.net>2018-06-23 20:52:09 +0900
commit99a9c28863ccccf25f6e95c5b38cb6884d922a7f (patch)
tree9101eb77970be97038e03cad61bf2430311083bd /drivers/net/ethernet/oki-semi/pch_gbe
parent90e3f637eb4d2e1fdb6a799e758a21c2a4e20a1d (diff)
net: pch_gbe: Use module_pci_driver()
Make use of the module_pci_driver() macro to remove some needless boilerplate code from the pch_gbe driver. This does have the side effect of removing the print of the driver's version during probe, but this is pretty useless information anyway - the version has changed only once whilst the driver has been in mainline, despite many changes being made to it before and since. Signed-off-by: Paul Burton <paul.burton@mips.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/oki-semi/pch_gbe')
-rw-r--r--drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c19
1 files changed, 1 insertions, 18 deletions
diff --git a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c
index 11c42aa42b8a..3f2dd36d45ad 100644
--- a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c
+++ b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c
@@ -2770,24 +2770,7 @@ static struct pci_driver pch_gbe_driver = {
.shutdown = pch_gbe_shutdown,
.err_handler = &pch_gbe_err_handler
};
-
-
-static int __init pch_gbe_init_module(void)
-{
- int ret;
-
- pr_info("EG20T PCH Gigabit Ethernet Driver - version %s\n",DRV_VERSION);
- ret = pci_register_driver(&pch_gbe_driver);
- return ret;
-}
-
-static void __exit pch_gbe_exit_module(void)
-{
- pci_unregister_driver(&pch_gbe_driver);
-}
-
-module_init(pch_gbe_init_module);
-module_exit(pch_gbe_exit_module);
+module_pci_driver(pch_gbe_driver);
MODULE_DESCRIPTION("EG20T PCH Gigabit ethernet Driver");
MODULE_AUTHOR("LAPIS SEMICONDUCTOR, <tshimizu818@gmail.com>");