2
* Copyright (C) 2013 Stefan Roese <sr@denx.de>
4
* SPDX-License-Identifier: GPL-2.0+
10
DECLARE_GLOBAL_DATA_PTR;
13
* Return selected boot device. On PPC4xx its only NOR flash right now.
15
u32 spl_boot_device(void)
17
return BOOT_DEVICE_NOR;
21
* SPL version of board_init_f()
23
void board_init_f(ulong bootflag)
26
* First we need to initialize the SDRAM, so that the real
27
* U-Boot or the OS (Linux) can be loaded
32
memset(__bss_start, '\0', __bss_end - __bss_start);
35
* Init global_data pointer. Has to be done before calling
36
* get_clocks(), as it stores some clock values into gd needed
37
* later on in the serial driver.
39
/* Pointer is writable since we allocated a register for it */
40
gd = (gd_t *)(CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_GBL_DATA_OFFSET);
41
/* Clear initial global data */
42
memset((void *)gd, 0, sizeof(gd_t));
45
* get_clocks() needs to be called so that the serial driver
51
* Do rudimental console / serial setup
53
preloader_console_init();
56
* Call board_init_r() (SPL framework version) to load and boot
59
board_init_r(NULL, 0);
60
/* Does not return!!! */