wl18xx: use module_platform_driver
authorDevendra Naga <devendra.aaru@gmail.com>
Wed, 29 Aug 2012 17:33:01 +0000 (23:03 +0530)
committerLuciano Coelho <luca@coelho.fi>
Thu, 27 Sep 2012 08:44:40 +0000 (11:44 +0300)
the driver's init and exit routines can be implemented with the
module_platform_driver, as the init and exit code is same as
that of the module_platform_driver

Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
Signed-off-by: Luciano Coelho <luca@coelho.fi>
drivers/net/wireless/ti/wl18xx/main.c

index 31cf6eba3a9e0f45a5bdef437f694e98e2d3c0fc..99364d4feac488f7a1c6b6d1b6c3f51dfad78a35 100644 (file)
@@ -1538,18 +1538,7 @@ static struct platform_driver wl18xx_driver = {
        }
 };
 
-static int __init wl18xx_init(void)
-{
-       return platform_driver_register(&wl18xx_driver);
-}
-module_init(wl18xx_init);
-
-static void __exit wl18xx_exit(void)
-{
-       platform_driver_unregister(&wl18xx_driver);
-}
-module_exit(wl18xx_exit);
-
+module_platform_driver(wl18xx_driver);
 module_param_named(ht_mode, ht_mode_param, charp, S_IRUSR);
 MODULE_PARM_DESC(ht_mode, "Force HT mode: wide or siso20");