omap2+: Minimize board specific init_early calls
[firefly-linux-kernel-4.4.55.git] / arch / arm / mach-omap2 / board-omap3touchbook.c
index db1f74fe6c4f0b24288d8be092d95207cc2e0d43..8e2a7ba4153b523e75ec88f79427136255464eca 100644 (file)
@@ -415,14 +415,15 @@ static struct omap_board_mux board_mux[] __initdata = {
 };
 #endif
 
-static void __init omap3_touchbook_init_irq(void)
+static void __init omap3_touchbook_init_early(void)
 {
-       omap3_mux_init(board_mux, OMAP_PACKAGE_CBB);
-       omap_board_config = omap3_touchbook_config;
-       omap_board_config_size = ARRAY_SIZE(omap3_touchbook_config);
        omap2_init_common_infrastructure();
        omap2_init_common_devices(mt46h32m32lf6_sdrc_params,
                                  mt46h32m32lf6_sdrc_params);
+}
+
+static void __init omap3_touchbook_init_irq(void)
+{
        omap_init_irq();
 #ifdef CONFIG_OMAP_32K_TIMER
        omap2_gp_clockevent_set_gptimer(12);
@@ -510,6 +511,10 @@ static struct omap_musb_board_data musb_board_data = {
 
 static void __init omap3_touchbook_init(void)
 {
+       omap3_mux_init(board_mux, OMAP_PACKAGE_CBB);
+       omap_board_config = omap3_touchbook_config;
+       omap_board_config_size = ARRAY_SIZE(omap3_touchbook_config);
+
        pm_power_off = omap3_touchbook_poweroff;
 
        omap3_touchbook_i2c_init();
@@ -538,8 +543,9 @@ static void __init omap3_touchbook_init(void)
 MACHINE_START(TOUCHBOOK, "OMAP3 touchbook Board")
        /* Maintainer: Gregoire Gentil - http://www.alwaysinnovating.com */
        .boot_params    = 0x80000100,
-       .map_io         = omap3_map_io,
        .reserve        = omap_reserve,
+       .map_io         = omap3_map_io,
+       .init_early     = omap3_touchbook_init_early,
        .init_irq       = omap3_touchbook_init_irq,
        .init_machine   = omap3_touchbook_init,
        .timer          = &omap_timer,