summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorLi Zetao <lizetao1@huawei.com>2023-08-21 22:03:45 +0800
committerKalle Valo <kvalo@kernel.org>2023-08-25 12:59:31 +0300
commit98fdd77d3df7ba269941f9a262d82a31537cf013 (patch)
treeb70f0548564678bca51bc0d3874c4b8e9f57db81 /drivers
parent4843aa3768e2c7f4dc61400c2db03671236d7c98 (diff)
wifi: wlcore: sdio: Use module_sdio_driver macro to simplify the code
Use the module_sdio_driver macro to simplify the code, which is the same as declaring with module_init() and module_exit(). Signed-off-by: Li Zetao <lizetao1@huawei.com> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20230821140345.3140493-1-lizetao1@huawei.com
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/ti/wlcore/sdio.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/net/wireless/ti/wlcore/sdio.c b/drivers/net/wireless/ti/wlcore/sdio.c
index cf8d909fa826..f0686635db46 100644
--- a/drivers/net/wireless/ti/wlcore/sdio.c
+++ b/drivers/net/wireless/ti/wlcore/sdio.c
@@ -442,18 +442,7 @@ static struct sdio_driver wl1271_sdio_driver = {
#endif
};
-static int __init wl1271_init(void)
-{
- return sdio_register_driver(&wl1271_sdio_driver);
-}
-
-static void __exit wl1271_exit(void)
-{
- sdio_unregister_driver(&wl1271_sdio_driver);
-}
-
-module_init(wl1271_init);
-module_exit(wl1271_exit);
+module_sdio_driver(wl1271_sdio_driver);
module_param(dump, bool, 0600);
MODULE_PARM_DESC(dump, "Enable sdio read/write dumps.");