aboutsummaryrefslogtreecommitdiff
path: root/files/uboot/b2260/uEnv_sd.txt
diff options
context:
space:
mode:
authorRiku Voipio <riku.voipio@linaro.org>2018-05-04 14:49:29 +0300
committerRiku Voipio <riku.voipio@linaro.org>2018-05-15 22:42:11 +0300
commit25234d13c6f86a4ace4125c7676b2db1a9b019e6 (patch)
tree368cb23f8e96cc3b7e3b166381edaa67735c0205 /files/uboot/b2260/uEnv_sd.txt
parent9d619ae36beb8233c510dd93d5c782bebe47fac8 (diff)
B2260: add support
Add support for B2260 images. Build command example: fai-diskimage -v --cspace /work/fai --hostname linaro-developer -S 3G \ --class SAVECACHE,STRETCH,DEBIAN,LINARO,DEVELOPER,B2260,UBOOT b2260raw Change-Id: Iccf44c89a3a4ab54368c461a2e7c4cb3a6321cfa Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
Diffstat (limited to 'files/uboot/b2260/uEnv_sd.txt')
-rw-r--r--files/uboot/b2260/uEnv_sd.txt31
1 files changed, 31 insertions, 0 deletions
diff --git a/files/uboot/b2260/uEnv_sd.txt b/files/uboot/b2260/uEnv_sd.txt
new file mode 100644
index 0000000..498e9f5
--- /dev/null
+++ b/files/uboot/b2260/uEnv_sd.txt
@@ -0,0 +1,31 @@
+# Init kernel and fdt config
+fdt_high=0xFFFFFFFF
+fdt_file=stih410-b2260.dtb
+fdt_load_addr=0x47000000
+kernel_file=uImage
+kernel_load_addr=0x60000000
+
+# Init device settings
+device_part=0:1
+
+# Init error message when filesystem load or read fails
+read_error_message=echo <ERROR> Unable to read \${part} filesystem on mmc at ${device_part} partition
+load_error_message=echo <ERROR> ${file} not available on mmc at ${device_part} partition
+
+# Check device interface availability and run load action if ok
+read_from_device=if \${part}ls mmc ${device_part}; then run load_kernel; else run read_error_message; fi
+
+# Load kernel and fdt, then launch boot action if ok
+load_kernel=if \${part}load mmc ${device_part} ${kernel_load_addr} ${kernel_file}; then run load_fdt ; else setenv file ${kernel_file}; run load_error_message; fi
+load_fdt=if \${part}load mmc ${device_part} ${fdt_load_addr} ${fdt_file}; then run run_boot; else setenv file ${fdt_file}; run load_error_message; fi
+
+# Check ethaddr and set it for kernel
+check_ethaddr=if test "x$ethaddr" = "x"; then echo <INFO> Set ethaddr...; readmac; if test "x$ethaddr" = "x"; then askenv ethaddr; fi; fi
+
+# Set bootargs and then boot
+run_boot=setenv bootargs console=ttyAS1,115200 CONSOLE=/dev/ttyAS1 consoleblank=0 root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait mem=992M@0x40000000 vmalloc=256m ; bootm ${kernel_load_addr} - ${fdt_load_addr}
+
+# Set boot command
+bootcmd=run check_ethaddr; echo <INFO> Load kernel and fdt to RAM...; run read_from_device
+
+boot