From 745ee219dd9a4643df54abe79dc37d22e5623266 Mon Sep 17 00:00:00 2001 From: Marcel Ziswiler Date: Mon, 27 Nov 2017 10:28:35 +0100 Subject: apalis-tk1: integrate tezi recovery In case of Tezi recovery do not stop regular auto booting but rather load the tezi.itb which got put at a fixed offset of 1M from the regular loadaddr. Signed-off-by: Marcel Ziswiler Acked-by: Stefan Agner --- board/toradex/apalis-tk1/apalis-tk1.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/board/toradex/apalis-tk1/apalis-tk1.c b/board/toradex/apalis-tk1/apalis-tk1.c index 7058cb3efc..a6a3897a75 100644 --- a/board/toradex/apalis-tk1/apalis-tk1.c +++ b/board/toradex/apalis-tk1/apalis-tk1.c @@ -35,7 +35,23 @@ int arch_misc_init(void) if (readl(NV_PA_BASE_SRAM + NVBOOTINFOTABLE_BOOTTYPE) == NVBOOTTYPE_RECOVERY) { printf("USB recovery mode, disabled autoboot\n"); +#ifdef CONFIG_TDX_EASY_INSTALLER + setenv("bootdelay", "-2"); + setenv("defargs", "pcie_aspm=off user_debug=30"); + setenv("fdt_high", ""); + setenv("initrd_high", ""); + setenv("setup", "setenv setupargs igb_mac=${ethaddr} " \ + "consoleblank=0 no_console_suspend=1 " \ + "console=${console},${baudrate}n8 ${memargs}"); + setenv("teziargs", "rootfstype=squashfs root=/dev/ram quiet " \ + "autoinstall"); + setenv("vidargs", "video=HDMI-A-1:640x480-16@60 hotplugfb"); + setenv("bootcmd", "run setup; setenv bootargs ${defargs} " \ + "${setupargs} ${vidargs} ${teziargs}; " \ + "bootm 0x80208000#config@${fdt_module}"); +#else /* CONFIG_TDX_EASY_INSTALLER */ setenv("bootdelay", "-1"); +#endif /* CONFIG_TDX_EASY_INSTALLER */ } /* PCB Version Indication: V1.2 and later have GPIO_PV0 wired to GND */ -- cgit v1.2.3