From c352f1e1218c8ff312b9f21e3930927f62427998 Mon Sep 17 00:00:00 2001 From: T Karthik Reddy Date: Wed, 13 Nov 2019 21:13:44 -0700 Subject: [PATCH] ARM: zynq: Add jtag distro boot support This patch adds new jtag distro boot command to look for bootscript file in DDR and execute it first incase of jtag bootmode. Signed-off-by: T Karthik Reddy Signed-off-by: Michal Simek --- board/xilinx/zynq/board.c | 2 +- include/configs/zynq-common.h | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/board/xilinx/zynq/board.c b/board/xilinx/zynq/board.c index 390d9482a7..420a5ca663 100644 --- a/board/xilinx/zynq/board.c +++ b/board/xilinx/zynq/board.c @@ -50,7 +50,7 @@ int board_late_init(void) env_set("modeboot", "sdboot"); break; case ZYNQ_BM_JTAG: - mode = "pxe dhcp"; + mode = "jtag pxe dhcp"; env_set("modeboot", "jtagboot"); break; default: diff --git a/include/configs/zynq-common.h b/include/configs/zynq-common.h index 22486c0e4c..2d53237df4 100644 --- a/include/configs/zynq-common.h +++ b/include/configs/zynq-common.h @@ -176,7 +176,16 @@ #define BOOTENV_DEV_NAME_NOR(devtypeu, devtypel, instance) \ "nor " +#define BOOT_TARGET_DEVICES_JTAG(func) func(JTAG, jtag, na) + +#define BOOTENV_DEV_JTAG(devtypeu, devtypel, instance) \ + "bootcmd_jtag=source $scriptaddr; echo SCRIPT FAILED: continuing...;\0" + +#define BOOTENV_DEV_NAME_JTAG(devtypeu, devtypel, instance) \ + "jtag " + #define BOOT_TARGET_DEVICES(func) \ + BOOT_TARGET_DEVICES_JTAG(func) \ BOOT_TARGET_DEVICES_MMC(func) \ BOOT_TARGET_DEVICES_QSPI(func) \ BOOT_TARGET_DEVICES_NAND(func) \ -- 2.39.5