void board_boot_order(u32 *spl_boot_list)
{
+#ifdef CONFIG_TPL_BUILD
+ const u32 jtag_magic = 0x1337c0de;
+ const u32 load_magic = 0xb33fc0de;
+
+ /*
+ * If JTAG probe sets special word at 0xe6300020, then it must
+ * put U-Boot into RAM and TPL will start it from RAM.
+ */
+ if (readl(CONFIG_TPL_TEXT_BASE + 0x20) == jtag_magic) {
+ printf("JTAG boot detected!\n");
+
+ while (readl(CONFIG_TPL_TEXT_BASE + 0x24) != load_magic)
+ ;
+
+ spl_boot_list[0] = BOOT_DEVICE_RAM;
+ spl_boot_list[1] = BOOT_DEVICE_NONE;
+
+ return;
+ }
+#endif
+
/* Boot from SPI NOR with YMODEM UART fallback. */
spl_boot_list[0] = BOOT_DEVICE_SPI;
spl_boot_list[1] = BOOT_DEVICE_UART;
CONFIG_ARM=y
+CONFIG_ENABLE_ARM_SOC_BOOT0_HOOK=y
CONFIG_ARCH_RMOBILE=y
CONFIG_SYS_TEXT_BASE=0x50000000
CONFIG_SPL_GPIO_SUPPORT=y
CONFIG_TPL=y
CONFIG_TPL_BOARD_INIT=y
CONFIG_TPL_NEEDS_SEPARATE_TEXT_BASE=y
+CONFIG_TPL_RAM_SUPPORT=y
+CONFIG_TPL_RAM_DEVICE=y
CONFIG_TPL_SERIAL_SUPPORT=y
CONFIG_TPL_SPI_FLASH_SUPPORT=y
CONFIG_TPL_SPI_LOAD=y