If enabled, build a live device tree after relocation. This can then be
used by driver model.
Signed-off-by: Simon Glass <sjg@chromium.org>
#endif
#include <mmc.h>
#include <nand.h>
+#include <of_live.h>
#include <onenand_uboot.h>
#include <scsi.h>
#include <serial.h>
}
#endif
+#ifdef CONFIG_OF_LIVE
+static int initr_of_live(void)
+{
+ return of_live_build(gd->fdt_blob,
+ (struct device_node **)&gd->of_root);
+}
+#endif
+
#ifdef CONFIG_DM
static int initr_dm(void)
{
initr_noncached,
#endif
bootstage_relocate,
+#ifdef CONFIG_OF_LIVE
+ initr_of_live,
+#endif
#ifdef CONFIG_DM
initr_dm,
#endif