summaryrefslogtreecommitdiffstats
path: root/drivers/watchdog/mei_wdt.c
diff options
context:
space:
mode:
authorTomas Winkler <tomas.winkler@intel.com>2016-10-19 15:33:28 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-10-28 14:21:21 +0200
commitb2a2f70863d2af5445b9a46b099c79cca981d002 (patch)
tree87074442d2e8764f12363b6b5e73a65b5f5b34a2 /drivers/watchdog/mei_wdt.c
parentmei: bus: add module_mei_cl_driver helper macro (diff)
downloadlinux-b2a2f70863d2af5445b9a46b099c79cca981d002.tar.xz
linux-b2a2f70863d2af5445b9a46b099c79cca981d002.zip
watchdog: mei_wdt: use module_mei_cl_driver macro
Replace boilerplate driver registration with module_mei_cl_driver macro. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Acked-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/watchdog/mei_wdt.c')
-rw-r--r--drivers/watchdog/mei_wdt.c20
1 files changed, 1 insertions, 19 deletions
diff --git a/drivers/watchdog/mei_wdt.c b/drivers/watchdog/mei_wdt.c
index 630bd189f167..116be477c8fd 100644
--- a/drivers/watchdog/mei_wdt.c
+++ b/drivers/watchdog/mei_wdt.c
@@ -699,25 +699,7 @@ static struct mei_cl_driver mei_wdt_driver = {
.remove = mei_wdt_remove,
};
-static int __init mei_wdt_init(void)
-{
- int ret;
-
- ret = mei_cldev_driver_register(&mei_wdt_driver);
- if (ret) {
- pr_err(KBUILD_MODNAME ": module registration failed\n");
- return ret;
- }
- return 0;
-}
-
-static void __exit mei_wdt_exit(void)
-{
- mei_cldev_driver_unregister(&mei_wdt_driver);
-}
-
-module_init(mei_wdt_init);
-module_exit(mei_wdt_exit);
+module_mei_cl_driver(mei_wdt_driver);
MODULE_AUTHOR("Intel Corporation");
MODULE_LICENSE("GPL");