提交 8c0aafe0 编写于 作者: S Sachin Kamat 提交者: Dmitry Torokhov

Input: twl4030-pwrbutton - use module_platform_driver_probe macro

module_platform_driver_probe() eliminates the boilerplate and simplifies
the code.
Signed-off-by: NSachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: NDmitry Torokhov <dmitry.torokhov@gmail.com>
上级 6b0bc60b
...@@ -114,18 +114,8 @@ static struct platform_driver twl4030_pwrbutton_driver = { ...@@ -114,18 +114,8 @@ static struct platform_driver twl4030_pwrbutton_driver = {
}, },
}; };
static int __init twl4030_pwrbutton_init(void) module_platform_driver_probe(twl4030_pwrbutton_driver,
{
return platform_driver_probe(&twl4030_pwrbutton_driver,
twl4030_pwrbutton_probe); twl4030_pwrbutton_probe);
}
module_init(twl4030_pwrbutton_init);
static void __exit twl4030_pwrbutton_exit(void)
{
platform_driver_unregister(&twl4030_pwrbutton_driver);
}
module_exit(twl4030_pwrbutton_exit);
MODULE_ALIAS("platform:twl4030_pwrbutton"); MODULE_ALIAS("platform:twl4030_pwrbutton");
MODULE_DESCRIPTION("Triton2 Power Button"); MODULE_DESCRIPTION("Triton2 Power Button");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册