ARM: i.MX51 babbage: prepare for multiboard support
Merge two initcalls to one and add a protector for the board type. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
7d7a982541
commit
70741174c9
|
@ -160,8 +160,11 @@ static void babbage_power_init(void)
|
|||
extern char flash_header_imx51_babbage_start[];
|
||||
extern char flash_header_imx51_babbage_end[];
|
||||
|
||||
static int f3s_devices_init(void)
|
||||
static int imx51_babbage_late_init(void)
|
||||
{
|
||||
if (!of_machine_is_compatible("fsl,imx51-babbage"))
|
||||
return 0;
|
||||
|
||||
babbage_power_init();
|
||||
|
||||
console_flush();
|
||||
|
@ -175,13 +178,6 @@ static int f3s_devices_init(void)
|
|||
BBU_HANDLER_FLAG_DEFAULT, (void *)flash_header_imx51_babbage_start,
|
||||
flash_header_imx51_babbage_end - flash_header_imx51_babbage_start, 0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
device_initcall(f3s_devices_init);
|
||||
|
||||
static int f3s_part_init(void)
|
||||
{
|
||||
device_detect_by_name("mmc0");
|
||||
|
||||
devfs_add_partition("mmc0", 0x00000, 0x40000, DEVFS_PARTITION_FIXED, "self0");
|
||||
|
@ -189,4 +185,4 @@ static int f3s_part_init(void)
|
|||
|
||||
return 0;
|
||||
}
|
||||
late_initcall(f3s_part_init);
|
||||
late_initcall(imx51_babbage_late_init);
|
||||
|
|
Loading…
Reference in New Issue