From: Wei Yongjun <weiyj.lk@gmail.com>
To: jkosina@suse.cz
Cc: yongjun_wei@trendmicro.com.cn, linux-input@vger.kernel.org
Subject: [PATCH -next] HID: steelseries: use module_hid_driver() to simplify the code
Date: Fri, 15 Mar 2013 23:07:02 +0800 [thread overview]
Message-ID: <CAPgLHd_6y1mr1moejftWGgrpO=vGxQUZ5Dz2v022kaFHdF-pVg@mail.gmail.com> (raw)
From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
module_hid_driver() makes the code simpler by eliminating
boilerplate code..
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
---
drivers/hid/hid-steelseries.c | 13 +------------
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git a/drivers/hid/hid-steelseries.c b/drivers/hid/hid-steelseries.c
index 98e66ac..9b0efb0 100644
--- a/drivers/hid/hid-steelseries.c
+++ b/drivers/hid/hid-steelseries.c
@@ -377,16 +377,5 @@ static struct hid_driver steelseries_srws1_driver = {
.report_fixup = steelseries_srws1_report_fixup
};
-static int __init steelseries_srws1_init(void)
-{
- return hid_register_driver(&steelseries_srws1_driver);
-}
-
-static void __exit steelseries_srws1_exit(void)
-{
- hid_unregister_driver(&steelseries_srws1_driver);
-}
-
-module_init(steelseries_srws1_init);
-module_exit(steelseries_srws1_exit);
+module_hid_driver(steelseries_srws1_driver);
MODULE_LICENSE("GPL");
next reply other threads:[~2013-03-15 15:07 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-15 15:07 Wei Yongjun [this message]
2013-03-18 9:53 ` [PATCH -next] HID: steelseries: use module_hid_driver() to simplify the code Jiri Kosina
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAPgLHd_6y1mr1moejftWGgrpO=vGxQUZ5Dz2v022kaFHdF-pVg@mail.gmail.com' \
--to=weiyj.lk@gmail.com \
--cc=jkosina@suse.cz \
--cc=linux-input@vger.kernel.org \
--cc=yongjun_wei@trendmicro.com.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.