]> git.karo-electronics.de Git - linux-beck.git/commitdiff
ARM: pxa: magician: Move platform_add_devices() to the end of magician_init()
authorPetr Cvek <petr.cvek@tul.cz>
Mon, 28 Sep 2015 21:42:23 +0000 (23:42 +0200)
committerRobert Jarzmik <robert.jarzmik@free.fr>
Wed, 14 Oct 2015 21:07:00 +0000 (23:07 +0200)
This patch moves platform_add_devices() (standard declaration of devices)
outside of the platform specific device declarations. Moving to the end
of the magician_init() clarifies the source code (standard and specific
declaration are not mixed).

Signed-off-by: Petr Cvek <petr.cvek@tul.cz>
Acked-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
arch/arm/mach-pxa/magician.c

index d77f95ddd198cfd4b40142c2d3d4fc48e660812a..d78ba05c97e050b32b042d8ce2bbd5125232034d 100644 (file)
@@ -852,7 +852,6 @@ static void __init magician_init(void)
        pxa_set_btuart_info(NULL);
 
        pwm_add_table(magician_pwm_lookup, ARRAY_SIZE(magician_pwm_lookup));
-       platform_add_devices(ARRAY_AND_SIZE(devices));
 
        pxa_set_ficp_info(&magician_ficp_info);
        pxa27x_set_i2c_power_info(&magician_i2c_power_info);
@@ -880,6 +879,8 @@ static void __init magician_init(void)
 
        regulator_register_always_on(0, "power", pwm_backlight_supply,
                ARRAY_SIZE(pwm_backlight_supply), 5000000);
+
+       platform_add_devices(ARRAY_AND_SIZE(devices));
 }
 
 MACHINE_START(MAGICIAN, "HTC Magician")