pinctrl: stm32: use builtin_platform_driver
authorGeliang Tang <geliangtang@gmail.com>
Fri, 18 Nov 2016 14:12:30 +0000 (22:12 +0800)
committerLinus Walleij <linus.walleij@linaro.org>
Tue, 22 Nov 2016 08:57:39 +0000 (09:57 +0100)
Use builtin_platform_driver() helper to simplify the code.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/stm32/pinctrl-stm32f429.c

index e9b15dc0654bc67371e2f1967350b560cd78a508..990b867b96254b59f748c87b27355384833bdf58 100644 (file)
@@ -1584,8 +1584,4 @@ static struct platform_driver stm32f429_pinctrl_driver = {
        },
 };
 
-static int __init stm32f429_pinctrl_init(void)
-{
-       return platform_driver_register(&stm32f429_pinctrl_driver);
-}
-device_initcall(stm32f429_pinctrl_init);
+builtin_platform_driver(stm32f429_pinctrl_driver);