From 3c22f3fcbdb9f919ebdfa87a2ec237ac2abb7e03 Mon Sep 17 00:00:00 2001 From: Yutang Jiang Date: Thu, 27 Oct 2016 23:45:45 +0800 Subject: [PATCH 05/93] armv8: set openwrt/lede default boot env for ls1043ardb Signed-off-by: Yutang Jiang --- include/configs/ls1043a_common.h | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/include/configs/ls1043a_common.h b/include/configs/ls1043a_common.h index 68678f3..1db05bb 100644 --- a/include/configs/ls1043a_common.h +++ b/include/configs/ls1043a_common.h @@ -273,6 +273,16 @@ "5m(kernel),1m(dtb),9m(file_system)" #endif +#define WRTBOOT_DEFAULT "setenv bootargs root=/dev/mtdblock6 " \ + "rootfstype=squashfs,jffs2 noinitrd earlycon=uart8250,mmio,0x21c0500 " \ + "console=ttyS0,115200 mtdparts=60000000.nor:1M(rcw),1M(u-boot)," \ + "1M(u-boot-env),1M(fman),1M(dtb),5M(kernel),54M(rootfs),64M(otherbank)" \ + " && cp.b 60400000 $fdtaddr 100000 && cp.b 60500000 $loadaddr 500000" \ + " && bootm $loadaddr - $fdtaddr" +#define WRTUPDATE_DEFAULT "tftp a0000000 /" \ + "lede-layerscape-64b-ls1043ardb-squashfs-firmware.bin && protect off all" \ + " && erase 60000000 +4000000 && cp.b a0000000 60000000 $filesize && reset" + /* Initial environment variables */ #define CONFIG_EXTRA_ENV_SETTINGS \ "hwconfig=fsl_ddr:bank_intlv=auto\0" \ @@ -286,6 +296,19 @@ "kernel_load=0xa0000000\0" \ "kernel_size=0x2800000\0" \ "console=ttyAMA0,38400n8\0" \ + "ethaddr=00:e0:0c:00:77:00\0" \ + "eth1addr=00:e0:0c:00:77:01\0" \ + "eth2addr=00:e0:0c:00:77:02\0" \ + "eth3addr=00:e0:0c:00:77:03\0" \ + "eth4addr=00:e0:0c:00:77:04\0" \ + "eth5addr=00:e0:0c:00:77:05\0" \ + "eth6addr=00:e0:0c:00:77:06\0" \ + "ethact=FM1@DTSEC2\0" \ + "loadaddr=82000000\0" \ + "ramdiskaddr=88000000\0" \ + "fdtaddr=8f000000\0" \ + "wrtboot=" WRTBOOT_DEFAULT "\0" \ + "wrtupdate=" WRTUPDATE_DEFAULT "\0" \ "mtdparts=" MTDPARTS_DEFAULT "\0" #define CONFIG_BOOTARGS "console=ttyS0,115200 root=/dev/ram0 " \ @@ -296,10 +319,9 @@ #define CONFIG_BOOTCOMMAND "sf probe && sf read $kernel_load " \ "e0000 f00000 && bootm $kernel_load" #else -#define CONFIG_BOOTCOMMAND "cp.b $kernel_start $kernel_load " \ - "$kernel_size && bootm $kernel_load" +#define CONFIG_BOOTCOMMAND "run wrtboot" #endif -#define CONFIG_BOOTDELAY 10 +#define CONFIG_BOOTDELAY 3 /* Monitor Command Prompt */ #define CONFIG_SYS_CBSIZE 512 /* Console I/O Buffer Size */ -- 1.7.9.5