* [PATCH] power: ab8500_btemp: use builtin_platform_driver
@ 2016-11-23 14:56 Geliang Tang
2016-11-23 15:47 ` Sebastian Reichel
0 siblings, 1 reply; 2+ messages in thread
From: Geliang Tang @ 2016-11-23 14:56 UTC (permalink / raw)
To: Sebastian Reichel; +Cc: Geliang Tang, linux-pm, linux-kernel
Use builtin_platform_driver() helper to simplify the code.
Signed-off-by: Geliang Tang <geliangtang@gmail.com>
---
drivers/power/supply/ab8500_btemp.c | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/drivers/power/supply/ab8500_btemp.c b/drivers/power/supply/ab8500_btemp.c
index 6ffdc18..f925e50 100644
--- a/drivers/power/supply/ab8500_btemp.c
+++ b/drivers/power/supply/ab8500_btemp.c
@@ -1193,17 +1193,12 @@ static struct platform_driver ab8500_btemp_driver = {
},
};
-static int __init ab8500_btemp_init(void)
-{
- return platform_driver_register(&ab8500_btemp_driver);
-}
-
static void __exit ab8500_btemp_exit(void)
{
platform_driver_unregister(&ab8500_btemp_driver);
}
-device_initcall(ab8500_btemp_init);
+builtin_platform_driver(ab8500_btemp_driver);
module_exit(ab8500_btemp_exit);
MODULE_LICENSE("GPL v2");
--
2.9.3
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-11-23 15:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-23 14:56 [PATCH] power: ab8500_btemp: use builtin_platform_driver Geliang Tang
2016-11-23 15:47 ` Sebastian Reichel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®