[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1468434589-18610-5-git-send-email-fabf@skynet.be>
Date: Wed, 13 Jul 2016 20:29:45 +0200
From: Fabian Frederick <fabf@...net.be>
To: Samuel Ortiz <samuel@...tiz.org>
Cc: linux-kernel@...r.kernel.org, irda-users@...ts.sourceforge.net,
davem@...emloft.net, fabf@...net.be
Subject: [PATCH 4/8 net-next] irda: esi-sir: use module_sirdev_driver() helper
Avoid using generic init/exit functions.
Signed-off-by: Fabian Frederick <fabf@...net.be>
---
drivers/net/irda/esi-sir.c | 16 ++--------------
1 file changed, 2 insertions(+), 14 deletions(-)
diff --git a/drivers/net/irda/esi-sir.c b/drivers/net/irda/esi-sir.c
index 019a3e8..65470e4 100644
--- a/drivers/net/irda/esi-sir.c
+++ b/drivers/net/irda/esi-sir.c
@@ -52,16 +52,6 @@ static struct dongle_driver esi = {
.set_speed = esi_change_speed,
};
-static int __init esi_sir_init(void)
-{
- return irda_register_dongle(&esi);
-}
-
-static void __exit esi_sir_cleanup(void)
-{
- irda_unregister_dongle(&esi);
-}
-
static int esi_open(struct sir_dev *dev)
{
struct qos_info *qos = &dev->qos;
@@ -147,11 +137,9 @@ static int esi_reset(struct sir_dev *dev)
return 0;
}
+module_sirdev_driver(esi);
+
MODULE_AUTHOR("Dag Brattli <dagb@...uit.no>");
MODULE_DESCRIPTION("Extended Systems JetEye PC dongle driver");
MODULE_LICENSE("GPL");
MODULE_ALIAS("irda-dongle-1"); /* IRDA_ESI_DONGLE */
-
-module_init(esi_sir_init);
-module_exit(esi_sir_cleanup);
-
--
2.8.1
Powered by blists - more mailing lists