summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath6kl/usb.c
diff options
context:
space:
mode:
authorHimangi Saraogi <himangi774@gmail.com>2014-08-01 21:41:15 +0530
committerKalle Valo <kvalo@qca.qualcomm.com>2014-08-04 09:10:53 +0300
commit17dc0b8068f9f01c56b0ade5c36b4c45a3339dda (patch)
treee5bb94f62a18be94e71b674a46b7bd6f82fba009 /drivers/net/wireless/ath/ath6kl/usb.c
parent855aed1220d2c94425ab01a85fe7a6f5c436940f (diff)
downloadop-kernel-dev-17dc0b8068f9f01c56b0ade5c36b4c45a3339dda.zip
op-kernel-dev-17dc0b8068f9f01c56b0ade5c36b4c45a3339dda.tar.gz
ath6kl: convert a driver to use module_usb_driver()
This converts a driver in drivers/net/* to use the module_usb_driver() macro which makes the code smaller and a bit simpler. Signed-off-by: Himangi Saraogi <himangi774@gmail.com> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath6kl/usb.c')
-rw-r--r--drivers/net/wireless/ath/ath6kl/usb.c21
1 files changed, 1 insertions, 20 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/usb.c b/drivers/net/wireless/ath/ath6kl/usb.c
index c443258..a6a5e40 100644
--- a/drivers/net/wireless/ath/ath6kl/usb.c
+++ b/drivers/net/wireless/ath/ath6kl/usb.c
@@ -1229,26 +1229,7 @@ static struct usb_driver ath6kl_usb_driver = {
.disable_hub_initiated_lpm = 1,
};
-static int ath6kl_usb_init(void)
-{
- int ret;
-
- ret = usb_register(&ath6kl_usb_driver);
- if (ret) {
- ath6kl_err("usb registration failed: %d\n", ret);
- return ret;
- }
-
- return 0;
-}
-
-static void ath6kl_usb_exit(void)
-{
- usb_deregister(&ath6kl_usb_driver);
-}
-
-module_init(ath6kl_usb_init);
-module_exit(ath6kl_usb_exit);
+module_usb_driver(ath6kl_usb_driver);
MODULE_AUTHOR("Atheros Communications, Inc.");
MODULE_DESCRIPTION("Driver support for Atheros AR600x USB devices");
OpenPOWER on IntegriCloud