summaryrefslogtreecommitdiff
path: root/drivers/staging/rtl8192e
diff options
context:
space:
mode:
authorKsenija Stanojevic <ksenija.stanojevic@gmail.com>2015-10-19 18:49:12 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-10-24 19:12:48 -0700
commitc1ccdddc2e60e73011d0a5e2f06913be84b8bafb (patch)
tree0a5a513528ab3f5510425d9b142e4424e919a81c /drivers/staging/rtl8192e
parent1e6e63283691a2a9048a35d9c6c59cf0abd342e4 (diff)
Staging: rtl8192e: Use module_pci_driver
Use module_pci_driver for drivers whose init and exit functions only register and unregister, respectively. Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8192e')
-rw-r--r--drivers/staging/rtl8192e/rtl8192e/rtl_core.c22
1 files changed, 1 insertions, 21 deletions
diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
index 2e3c25c37e36..8f989a95a019 100644
--- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
+++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
@@ -2775,24 +2775,7 @@ bool rtl92e_disable_nic(struct net_device *dev)
return true;
}
-static int __init _rtl92e_pci_module_init(void)
-{
- pr_info("\nLinux kernel driver for RTL8192E WLAN cards\n");
- pr_info("Copyright (c) 2007-2008, Realsil Wlan Driver\n");
-
- if (0 != pci_register_driver(&rtl8192_pci_driver)) {
- /*pci_unregister_driver (&rtl8192_pci_driver);*/
- return -ENODEV;
- }
- return 0;
-}
-
-static void __exit _rtl92e_pci_module_exit(void)
-{
- pci_unregister_driver(&rtl8192_pci_driver);
-
- RT_TRACE(COMP_DOWN, "Exiting");
-}
+module_pci_driver(rtl8192_pci_driver);
void rtl92e_check_rfctrl_gpio_timer(unsigned long data)
{
@@ -2809,9 +2792,6 @@ void rtl92e_check_rfctrl_gpio_timer(unsigned long data)
/***************************************************************************
------------------- module init / exit stubs ----------------
****************************************************************************/
-module_init(_rtl92e_pci_module_init);
-module_exit(_rtl92e_pci_module_exit);
-
MODULE_DESCRIPTION("Linux driver for Realtek RTL819x WiFi cards");
MODULE_AUTHOR(DRV_COPYRIGHT " " DRV_AUTHOR);
MODULE_VERSION(DRV_VERSION);