gpio: etraxfs: use builtin_platform_driver
authorGeliang Tang <geliangtang@gmail.com>
Fri, 18 Nov 2016 14:12:27 +0000 (22:12 +0800)
committerLinus Walleij <linus.walleij@linaro.org>
Tue, 22 Nov 2016 09:14:22 +0000 (10:14 +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/gpio/gpio-etraxfs.c

index 00b022c9acb316e17b398029ee78ab6c44fc94c2..a254d5b07b941ecdb2c9e2fbe8a3ab54c946ee78 100644 (file)
@@ -471,9 +471,4 @@ static struct platform_driver etraxfs_gpio_driver = {
        .probe  = etraxfs_gpio_probe,
 };
 
-static int __init etraxfs_gpio_init(void)
-{
-       return platform_driver_register(&etraxfs_gpio_driver);
-}
-
-device_initcall(etraxfs_gpio_init);
+builtin_platform_driver(etraxfs_gpio_driver);