rt2x00: rt2800pci: use module_pci_driver macro
authorGabor Juhos <juhosg@openwrt.org>
Thu, 17 Oct 2013 07:42:35 +0000 (09:42 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 18 Oct 2013 18:07:00 +0000 (14:07 -0400)
Use the module_pci_driver() macro to make the code simpler
by eliminating module_init and module_exit calls.

Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rt2x00/rt2800pci.c

index 260d2fdadc76074670ae4696ec7b8c8691f8e5a9..b504455b4fec10c69c4cc09c1f44be4b92ac3be4 100644 (file)
@@ -470,16 +470,4 @@ static struct pci_driver rt2800pci_driver = {
        .resume         = rt2x00pci_resume,
 };
 
-
-static int __init rt2800pci_init(void)
-{
-       return pci_register_driver(&rt2800pci_driver);
-}
-
-static void __exit rt2800pci_exit(void)
-{
-       pci_unregister_driver(&rt2800pci_driver);
-}
-
-module_init(rt2800pci_init);
-module_exit(rt2800pci_exit);
+module_pci_driver(rt2800pci_driver);