Commit 10d1491b3dea43182aec5cdce8f81ca520400c4b

Authored by Linus Walleij
Committed by Tom Rini
1 parent 4bb6650632

vexpress64: juno: add default NOR flash boot

This modifies the vexpress64 Juno configuration so that
it will by default load and boot a kernel and a device tree
from the images stored in the NOR flash. When we are
at it, also define the proper command line for the Juno and
indicate that the USB stick (/dev/sda1) is the default
root file system.

Reviewed-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>

Showing 1 changed file with 29 additions and 1 deletions Side-by-side Diff

include/configs/vexpress_aemv8a.h
... ... @@ -198,8 +198,35 @@
198 198 #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1
199 199  
200 200 /* Initial environment variables */
201   -#ifdef CONFIG_TARGET_VEXPRESS64_BASE_FVP
  201 +#ifdef CONFIG_TARGET_VEXPRESS64_JUNO
  202 +/*
  203 + * Defines where the kernel and FDT exist in NOR flash and where it will
  204 + * be copied into DRAM
  205 + */
202 206 #define CONFIG_EXTRA_ENV_SETTINGS \
  207 + "kernel_name=Image\0" \
  208 + "kernel_addr=0x80000000\0" \
  209 + "fdt_name=juno\0" \
  210 + "fdt_addr=0x83000000\0" \
  211 + "fdt_high=0xffffffffffffffff\0" \
  212 + "initrd_high=0xffffffffffffffff\0" \
  213 +
  214 +/* Assume we boot with root on the first partition of a USB stick */
  215 +#define CONFIG_BOOTARGS "console=ttyAMA0,115200n8 " \
  216 + "root=/dev/sda1 rw " \
  217 + "earlyprintk=pl011,0x7ff80000 debug user_debug=31 "\
  218 + "loglevel=9"
  219 +
  220 +/* Copy the kernel and FDT to DRAM memory and boot */
  221 +#define CONFIG_BOOTCOMMAND "afs load ${kernel_name} ${kernel_addr} ; " \
  222 + "afs load ${fdt_name} ${fdt_addr} ; " \
  223 + "fdt addr ${fdt_addr}; fdt resize; " \
  224 + "booti ${kernel_addr} - ${fdt_addr}"
  225 +
  226 +#define CONFIG_BOOTDELAY 1
  227 +
  228 +#elif CONFIG_TARGET_VEXPRESS64_BASE_FVP
  229 +#define CONFIG_EXTRA_ENV_SETTINGS \
203 230 "kernel_name=uImage\0" \
204 231 "kernel_addr=0x80000000\0" \
205 232 "initrd_name=ramdisk.img\0" \
... ... @@ -246,6 +273,7 @@
246 273 #define CONFIG_SYS_NO_FLASH
247 274 #else
248 275 #define CONFIG_CMD_FLASH
  276 +#define CONFIG_CMD_ARMFLASH
249 277 #define CONFIG_SYS_FLASH_CFI 1
250 278 #define CONFIG_FLASH_CFI_DRIVER 1
251 279 #define CONFIG_SYS_FLASH_BASE 0x08000000