#include <hang.h>
#include <image.h>
#include <irq_func.h>
+#include <lmb.h>
#include <log.h>
#include <net.h>
#include <asm/cache.h>
#include <command.h>
#include <console.h>
#include <dm.h>
+#include <efi_loader.h>
#include <env.h>
#include <env_internal.h>
#include <fdtdec.h>
#include <initcall.h>
#include <kgdb.h>
#include <irq_func.h>
+#include <led.h>
#include <malloc.h>
#include <mapmem.h>
#include <miiphy.h>
#include <dm/ofnode.h>
#include <linux/compiler.h>
#include <linux/err.h>
-#include <efi_loader.h>
#include <wdt.h>
#include <asm-generic/gpio.h>
-#include <efi_loader.h>
#include <relocate.h>
DECLARE_GLOBAL_DATA_PTR;
ulong start;
#if CONFIG_IS_ENABLED(SYS_MALLOC_F)
- debug("Pre-reloc malloc() used %#lx bytes (%ld KB)\n", gd->malloc_ptr,
+ debug("Pre-reloc malloc() used %#x bytes (%d KB)\n", gd->malloc_ptr,
gd->malloc_ptr / 1024);
#endif
/* The malloc area is immediately below the monitor copy in DRAM */
*/
start = gd->relocaddr - TOTAL_MALLOC_LEN;
gd_set_malloc_start(start);
- mem_malloc_init((ulong)map_sysmem(start, TOTAL_MALLOC_LEN),
- TOTAL_MALLOC_LEN);
+ mem_malloc_init(start, TOTAL_MALLOC_LEN);
return 0;
}
oftree_reset();
- /* Save the pre-reloc driver model and start a new one */
- gd->dm_root_f = gd->dm_root;
+ /* Drop the pre-reloc driver model and start a new one */
gd->dm_root = NULL;
#ifdef CONFIG_TIMER
gd->timer = NULL;
}
#endif
-#if defined(CONFIG_LED_STATUS)
static int initr_status_led(void)
{
-#if defined(CONFIG_LED_STATUS_BOOT)
- status_led_set(CONFIG_LED_STATUS_BOOT, CONFIG_LED_STATUS_BLINKING);
-#else
status_led_init();
-#endif
+
+ return 0;
+}
+
+static int initr_boot_led_blink(void)
+{
+ status_led_boot_blink();
+
+ led_boot_blink();
+
return 0;
}
-#endif
-#ifdef CONFIG_CMD_NET
+static int initr_boot_led_on(void)
+{
+ led_boot_on();
+
+ return 0;
+}
+
+#if defined(CONFIG_CMD_NET)
static int initr_net(void)
{
puts("Net: ");
}
#endif
+static int initr_lmb(void)
+{
+ if (CONFIG_IS_ENABLED(LMB))
+ return lmb_init();
+ else
+ return 0;
+}
+
static int dm_announce(void)
{
int device_count;
uclass_count);
if (CONFIG_IS_ENABLED(OF_REAL))
printf(", devicetree: %s", fdtdec_get_srcname());
+ if (CONFIG_IS_ENABLED(UPL))
+ printf(", universal payload active");
printf("\n");
if (IS_ENABLED(CONFIG_OF_HAS_PRIOR_STAGE) &&
(gd->fdt_src == FDTSRC_SEPARATE ||
#ifdef CONFIG_CLOCKS
set_cpu_clk_info, /* Setup clock information */
#endif
+ initr_lmb,
#ifdef CONFIG_EFI_LOADER
efi_memory_init,
#endif
#if defined(CONFIG_MICROBLAZE) || defined(CONFIG_M68K)
timer_init, /* initialize timer */
#endif
-#if defined(CONFIG_LED_STATUS)
initr_status_led,
-#endif
+ initr_boot_led_blink,
/* PPC has a udelay(20) here dating from 2002. Why? */
#ifdef CONFIG_BOARD_LATE_INIT
board_late_init,
#ifdef CONFIG_PCI_ENDPOINT
pci_ep_init,
#endif
-#ifdef CONFIG_CMD_NET
+#if defined(CONFIG_CMD_NET)
INIT_FUNC_WATCHDOG_RESET
initr_net,
#endif
#if defined(CFG_PRAM)
initr_mem,
#endif
+ initr_boot_led_on,
run_main_loop,
};