Skip to content

Commit

Permalink
ARM: OMAP: Introduce SoC specific early_init
Browse files Browse the repository at this point in the history
Introduce them for each omap variant and just make them all call
omap2_init_common_infrastructure for now. Do this for each board-*.c
file except for board-generic and board-omap3beagle as they use
the same machine ID for multiple SoCs.

No functional changes.

Signed-off-by: Tony Lindgren <tony@atomide.com>
  • Loading branch information
Tony Lindgren committed Aug 24, 2011
1 parent a4ca9db commit 8f5b5a4
Show file tree
Hide file tree
Showing 27 changed files with 80 additions and 156 deletions.
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-2430sdp.c
Original file line number Diff line number Diff line change
Expand Up @@ -141,11 +141,6 @@ static struct omap_board_config_kernel sdp2430_config[] __initdata = {
{OMAP_TAG_LCD, &sdp2430_lcd_config},
};

static void __init omap_2430sdp_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct regulator_consumer_supply sdp2430_vmmc1_supplies[] = {
REGULATOR_SUPPLY("vmmc", "omap_hsmmc.0"),
};
Expand Down Expand Up @@ -259,7 +254,7 @@ MACHINE_START(OMAP_2430SDP, "OMAP2430 sdp2430 board")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap_2430sdp_map_io,
.init_early = omap_2430sdp_init_early,
.init_early = omap2430_init_early,
.init_irq = omap2_init_irq,
.init_machine = omap_2430sdp_init,
.timer = &omap2_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-3430sdp.c
Original file line number Diff line number Diff line change
Expand Up @@ -225,11 +225,6 @@ static struct omap_dss_board_info sdp3430_dss_data = {
static struct omap_board_config_kernel sdp3430_config[] __initdata = {
};

static void __init omap_3430sdp_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct omap2_hsmmc_info mmc[] = {
{
.mmc = 1,
Expand Down Expand Up @@ -732,7 +727,7 @@ MACHINE_START(OMAP_3430SDP, "OMAP3430 3430SDP board")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = omap_3430sdp_init_early,
.init_early = omap3430_init_early,
.init_irq = omap3_init_irq,
.init_machine = omap_3430sdp_init,
.timer = &omap3_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-3630sdp.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,6 @@ static const struct usbhs_omap_board_data usbhs_bdata __initconst = {
static struct omap_board_config_kernel sdp_config[] __initdata = {
};

static void __init omap_sdp_init_early(void)
{
omap2_init_common_infrastructure();
}

#ifdef CONFIG_OMAP_MUX
static struct omap_board_mux board_mux[] __initdata = {
{ .reg_offset = OMAP_MUX_TERMINATOR },
Expand Down Expand Up @@ -218,7 +213,7 @@ MACHINE_START(OMAP_3630SDP, "OMAP 3630SDP board")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = omap_sdp_init_early,
.init_early = omap3630_init_early,
.init_irq = omap3_init_irq,
.init_machine = omap_sdp_init,
.timer = &omap3_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-4430sdp.c
Original file line number Diff line number Diff line change
Expand Up @@ -389,11 +389,6 @@ static struct omap_board_config_kernel sdp4430_config[] __initdata = {
{ OMAP_TAG_LCD, &sdp4430_lcd_config },
};

static void __init omap_4430sdp_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct omap_musb_board_data musb_board_data = {
.interface_type = MUSB_INTERFACE_UTMI,
.mode = MUSB_OTG,
Expand Down Expand Up @@ -841,7 +836,7 @@ MACHINE_START(OMAP_4430SDP, "OMAP4430 4430SDP board")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap_4430sdp_map_io,
.init_early = omap_4430sdp_init_early,
.init_early = omap4430_init_early,
.init_irq = gic_init_irq,
.init_machine = omap_4430sdp_init,
.timer = &omap4_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-am3517crane.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,6 @@ static struct omap_board_mux board_mux[] __initdata = {
};
#endif

static void __init am3517_crane_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct usbhs_omap_board_data usbhs_bdata __initdata = {
.port_mode[0] = OMAP_EHCI_PORT_MODE_PHY,
.port_mode[1] = OMAP_USBHS_PORT_MODE_UNUSED,
Expand Down Expand Up @@ -101,7 +96,7 @@ MACHINE_START(CRANEBOARD, "AM3517/05 CRANEBOARD")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = am3517_crane_init_early,
.init_early = am35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = am3517_crane_init,
.timer = &omap3_timer,
Expand Down
6 changes: 1 addition & 5 deletions arch/arm/mach-omap2/board-am3517evm.c
Original file line number Diff line number Diff line change
Expand Up @@ -362,10 +362,6 @@ static struct omap_dss_board_info am3517_evm_dss_data = {
/*
* Board initialization
*/
static void __init am3517_evm_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct omap_musb_board_data musb_board_data = {
.interface_type = MUSB_INTERFACE_ULPI,
Expand Down Expand Up @@ -493,7 +489,7 @@ MACHINE_START(OMAP3517EVM, "OMAP3517/AM3517 EVM")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = am3517_evm_init_early,
.init_early = am35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = am3517_evm_init,
.timer = &omap3_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-apollon.c
Original file line number Diff line number Diff line change
Expand Up @@ -273,11 +273,6 @@ static struct omap_board_config_kernel apollon_config[] __initdata = {
{ OMAP_TAG_LCD, &apollon_lcd_config },
};

static void __init omap_apollon_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct gpio apollon_gpio_leds[] __initdata = {
{ LED0_GPIO13, GPIOF_OUT_INIT_LOW, "LED0" }, /* LED0 - AA10 */
{ LED1_GPIO14, GPIOF_OUT_INIT_LOW, "LED1" }, /* LED1 - AA6 */
Expand Down Expand Up @@ -353,7 +348,7 @@ MACHINE_START(OMAP_APOLLON, "OMAP24xx Apollon")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap_apollon_map_io,
.init_early = omap_apollon_init_early,
.init_early = omap2420_init_early,
.init_irq = omap2_init_irq,
.init_machine = omap_apollon_init,
.timer = &omap2_timer,
Expand Down
9 changes: 2 additions & 7 deletions arch/arm/mach-omap2/board-cm-t35.c
Original file line number Diff line number Diff line change
Expand Up @@ -471,11 +471,6 @@ static void __init cm_t35_init_i2c(void)
omap3_pmic_init("tps65930", &cm_t35_twldata);
}

static void __init cm_t35_init_early(void)
{
omap2_init_common_infrastructure();
}

#ifdef CONFIG_OMAP_MUX
static struct omap_board_mux board_mux[] __initdata = {
/* nCS and IRQ for CM-T35 ethernet */
Expand Down Expand Up @@ -637,7 +632,7 @@ MACHINE_START(CM_T35, "Compulab CM-T35")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = cm_t35_init_early,
.init_early = omap35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = cm_t35_init,
.timer = &omap3_timer,
Expand All @@ -647,7 +642,7 @@ MACHINE_START(CM_T3730, "Compulab CM-T3730")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = cm_t35_init_early,
.init_early = omap3630_init_early,
.init_irq = omap3_init_irq,
.init_machine = cm_t3730_init,
.timer = &omap3_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-cm-t3517.c
Original file line number Diff line number Diff line change
Expand Up @@ -251,11 +251,6 @@ static inline void cm_t3517_init_nand(void) {}
static struct omap_board_config_kernel cm_t3517_config[] __initdata = {
};

static void __init cm_t3517_init_early(void)
{
omap2_init_common_infrastructure();
}

#ifdef CONFIG_OMAP_MUX
static struct omap_board_mux board_mux[] __initdata = {
/* GPIO186 - Green LED */
Expand Down Expand Up @@ -302,7 +297,7 @@ MACHINE_START(CM_T3517, "Compulab CM-T3517")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = cm_t3517_init_early,
.init_early = am35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = cm_t3517_init,
.timer = &omap3_timer,
Expand Down
8 changes: 1 addition & 7 deletions arch/arm/mach-omap2/board-devkit8000.c
Original file line number Diff line number Diff line change
Expand Up @@ -397,12 +397,6 @@ static struct platform_device keys_gpio = {
},
};


static void __init devkit8000_init_early(void)
{
omap2_init_common_infrastructure();
}

static void __init devkit8000_init_irq(void)
{
omap3_init_irq();
Expand Down Expand Up @@ -670,7 +664,7 @@ MACHINE_START(DEVKIT8000, "OMAP3 Devkit8000")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = devkit8000_init_early,
.init_early = omap35xx_init_early,
.init_irq = devkit8000_init_irq,
.init_machine = devkit8000_init,
.timer = &omap3_secure_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-h4.c
Original file line number Diff line number Diff line change
Expand Up @@ -290,11 +290,6 @@ static struct omap_board_config_kernel h4_config[] __initdata = {
{ OMAP_TAG_LCD, &h4_lcd_config },
};

static void __init omap_h4_init_early(void)
{
omap2_init_common_infrastructure();
}

static void __init omap_h4_init_irq(void)
{
omap2_init_irq();
Expand Down Expand Up @@ -385,7 +380,7 @@ MACHINE_START(OMAP_H4, "OMAP2420 H4 board")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap_h4_map_io,
.init_early = omap_h4_init_early,
.init_early = omap2420_init_early,
.init_irq = omap_h4_init_irq,
.init_machine = omap_h4_init,
.timer = &omap2_timer,
Expand Down
9 changes: 2 additions & 7 deletions arch/arm/mach-omap2/board-igep0020.c
Original file line number Diff line number Diff line change
Expand Up @@ -491,11 +491,6 @@ static struct platform_device *igep_devices[] __initdata = {
&igep_vwlan_device,
};

static void __init igep_init_early(void)
{
omap2_init_common_infrastructure();
}

static int igep2_keymap[] = {
KEY(0, 0, KEY_LEFT),
KEY(0, 1, KEY_RIGHT),
Expand Down Expand Up @@ -675,7 +670,7 @@ MACHINE_START(IGEP0020, "IGEP v2 board")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = igep_init_early,
.init_early = omap35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = igep_init,
.timer = &omap3_timer,
Expand All @@ -685,7 +680,7 @@ MACHINE_START(IGEP0030, "IGEP OMAP3 module")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = igep_init_early,
.init_early = omap35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = igep_init,
.timer = &omap3_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-ldp.c
Original file line number Diff line number Diff line change
Expand Up @@ -193,11 +193,6 @@ static struct omap_board_config_kernel ldp_config[] __initdata = {
{ OMAP_TAG_LCD, &ldp_lcd_config },
};

static void __init omap_ldp_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct twl4030_gpio_platform_data ldp_gpio_data = {
.gpio_base = OMAP_MAX_GPIO_LINES,
.irq_base = TWL4030_GPIO_IRQ_BASE,
Expand Down Expand Up @@ -336,7 +331,7 @@ MACHINE_START(OMAP_LDP, "OMAP LDP board")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = omap_ldp_init_early,
.init_early = omap3430_init_early,
.init_irq = omap3_init_irq,
.init_machine = omap_ldp_init,
.timer = &omap3_timer,
Expand Down
11 changes: 3 additions & 8 deletions arch/arm/mach-omap2/board-n8x0.c
Original file line number Diff line number Diff line change
Expand Up @@ -622,11 +622,6 @@ static void __init n8x0_map_io(void)
omap242x_map_common_io();
}

static void __init n8x0_init_early(void)
{
omap2_init_common_infrastructure();
}

#ifdef CONFIG_OMAP_MUX
static struct omap_board_mux board_mux[] __initdata = {
/* I2S codec port pins for McBSP block */
Expand Down Expand Up @@ -698,7 +693,7 @@ MACHINE_START(NOKIA_N800, "Nokia N800")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = n8x0_map_io,
.init_early = n8x0_init_early,
.init_early = omap2420_init_early,
.init_irq = omap2_init_irq,
.init_machine = n8x0_init_machine,
.timer = &omap2_timer,
Expand All @@ -708,7 +703,7 @@ MACHINE_START(NOKIA_N810, "Nokia N810")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = n8x0_map_io,
.init_early = n8x0_init_early,
.init_early = omap2420_init_early,
.init_irq = omap2_init_irq,
.init_machine = n8x0_init_machine,
.timer = &omap2_timer,
Expand All @@ -718,7 +713,7 @@ MACHINE_START(NOKIA_N810_WIMAX, "Nokia N810 WiMAX")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = n8x0_map_io,
.init_early = n8x0_init_early,
.init_early = omap2420_init_early,
.init_irq = omap2_init_irq,
.init_machine = n8x0_init_machine,
.timer = &omap2_timer,
Expand Down
7 changes: 1 addition & 6 deletions arch/arm/mach-omap2/board-omap3evm.c
Original file line number Diff line number Diff line change
Expand Up @@ -520,11 +520,6 @@ static int __init omap3_evm_i2c_init(void)
static struct omap_board_config_kernel omap3_evm_config[] __initdata = {
};

static void __init omap3_evm_init_early(void)
{
omap2_init_common_infrastructure();
}

static struct usbhs_omap_board_data usbhs_bdata __initdata = {

.port_mode[0] = OMAP_USBHS_PORT_MODE_UNUSED,
Expand Down Expand Up @@ -684,7 +679,7 @@ MACHINE_START(OMAP3EVM, "OMAP3 EVM")
.boot_params = 0x80000100,
.reserve = omap_reserve,
.map_io = omap3_map_io,
.init_early = omap3_evm_init_early,
.init_early = omap35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = omap3_evm_init,
.timer = &omap3_timer,
Expand Down
9 changes: 2 additions & 7 deletions arch/arm/mach-omap2/board-omap3logic.c
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,6 @@ static inline void __init board_smsc911x_init(void)
gpmc_smsc911x_init(&board_smsc911x_data);
}

static void __init omap3logic_init_early(void)
{
omap2_init_common_infrastructure();
}

#ifdef CONFIG_OMAP_MUX
static struct omap_board_mux board_mux[] __initdata = {
{ .reg_offset = OMAP_MUX_TERMINATOR },
Expand All @@ -211,7 +206,7 @@ static void __init omap3logic_init(void)
MACHINE_START(OMAP3_TORPEDO, "Logic OMAP3 Torpedo board")
.boot_params = 0x80000100,
.map_io = omap3_map_io,
.init_early = omap3logic_init_early,
.init_early = omap35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = omap3logic_init,
.timer = &omap3_timer,
Expand All @@ -220,7 +215,7 @@ MACHINE_END
MACHINE_START(OMAP3530_LV_SOM, "OMAP Logic 3530 LV SOM board")
.boot_params = 0x80000100,
.map_io = omap3_map_io,
.init_early = omap3logic_init_early,
.init_early = omap35xx_init_early,
.init_irq = omap3_init_irq,
.init_machine = omap3logic_init,
.timer = &omap3_timer,
Expand Down
Loading

0 comments on commit 8f5b5a4

Please sign in to comment.