summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/cw1200
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2013-05-30 15:42:54 +0400
committerJohn W. Linville <linville@tuxdriver.com>2013-05-30 22:45:25 +0400
commitd071c0430c6ae42fedec78f1ec2e37603adb8c78 (patch)
treeddeb7a989331218c9ae470cf3d15906082d54d2f /drivers/net/wireless/cw1200
parentc0dc79d607c39f5f6c6fd6cc8119b81639a6d6f3 (diff)
downloadlinux-d071c0430c6ae42fedec78f1ec2e37603adb8c78.tar.xz
cw1200: use module_spi_driver to simplify the code
module_spi_driver() makes the code simpler by eliminating boilerplate code. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/cw1200')
-rw-r--r--drivers/net/wireless/cw1200/cw1200_spi.c15
1 files changed, 1 insertions, 14 deletions
diff --git a/drivers/net/wireless/cw1200/cw1200_spi.c b/drivers/net/wireless/cw1200/cw1200_spi.c
index b957d4a01c52..feb541bb507c 100644
--- a/drivers/net/wireless/cw1200/cw1200_spi.c
+++ b/drivers/net/wireless/cw1200/cw1200_spi.c
@@ -468,17 +468,4 @@ static struct spi_driver spi_driver = {
},
};
-/* Init Module function -> Called by insmod */
-static int __init cw1200_spi_init(void)
-{
- return spi_register_driver(&spi_driver);
-}
-
-/* Called at Driver Unloading */
-static void __exit cw1200_spi_exit(void)
-{
- spi_unregister_driver(&spi_driver);
-}
-
-module_init(cw1200_spi_init);
-module_exit(cw1200_spi_exit);
+module_spi_driver(spi_driver);