linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c-taos-evm: Use module_serio_driver()
@ 2014-06-13 19:52 Christoph Jaeger
  2014-06-13 21:23 ` Jean Delvare
       [not found] ` <1402689144-20259-1-git-send-email-christophjaeger-vYTEC60ixJUAvxtiuMwx3w@public.gmane.org>
  0 siblings, 2 replies; 3+ messages in thread
From: Christoph Jaeger @ 2014-06-13 19:52 UTC (permalink / raw)
  To: jdelvare-l3A5Bk7waGM, wsa-z923LK4zBo2bacvFa/9K2g
  Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA, Christoph Jaeger

Get rid of some boilerplate code by using module_serio_driver().

Signed-off-by: Christoph Jaeger <christophjaeger-vYTEC60ixJUAvxtiuMwx3w@public.gmane.org>
---
 drivers/i2c/busses/i2c-taos-evm.c | 13 +------------
 1 file changed, 1 insertion(+), 12 deletions(-)

diff --git a/drivers/i2c/busses/i2c-taos-evm.c b/drivers/i2c/busses/i2c-taos-evm.c
index 0576026..10855a0 100644
--- a/drivers/i2c/busses/i2c-taos-evm.c
+++ b/drivers/i2c/busses/i2c-taos-evm.c
@@ -311,19 +311,8 @@ static struct serio_driver taos_drv = {
 	.interrupt	= taos_interrupt,
 };
 
-static int __init taos_init(void)
-{
-	return serio_register_driver(&taos_drv);
-}
-
-static void __exit taos_exit(void)
-{
-	serio_unregister_driver(&taos_drv);
-}
+module_serio_driver(taos_drv);
 
 MODULE_AUTHOR("Jean Delvare <jdelvare-l3A5Bk7waGM@public.gmane.org>");
 MODULE_DESCRIPTION("TAOS evaluation module driver");
 MODULE_LICENSE("GPL");
-
-module_init(taos_init);
-module_exit(taos_exit);
-- 
1.9.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-06-27 11:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-13 19:52 [PATCH] i2c-taos-evm: Use module_serio_driver() Christoph Jaeger
2014-06-13 21:23 ` Jean Delvare
     [not found] ` <1402689144-20259-1-git-send-email-christophjaeger-vYTEC60ixJUAvxtiuMwx3w@public.gmane.org>
2014-06-27 11:25   ` Wolfram Sang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).