diff options
author | Steve Kipisz <s-kipisz2@ti.com> | 2013-02-28 12:08:30 -0600 |
---|---|---|
committer | Franklin S. Cooper Jr <fcooper@ti.com> | 2013-03-20 12:42:53 -0500 |
commit | b94c42dd9075a89941f4ad53e66422a04c67093e (patch) | |
tree | df4b9cb520ed7990326ab3bad39cf0025782ed28 | |
parent | 9a6c4d6604a39a94a29b370a4bea7cd7afa0177a (diff) |
am335x_evm:fix mmc boot environment settings
Original patch from arago-project.org u-boot-am33x
[PATCH] am335x_evm: fix mmc boot environment settings
Commit id: 3fdd541db2ad8202476ba2c5ef22ab034c85618d
* Fixed the MMC boot environment settings to try first loading
the uImage from the FAT partition instead of the ext2 partition.
* Changed to load the kernel image a kloadaddr to avoid the need
to relocate the kernel image during boot.
* Added ip_method to mmcargs
* Use bootargs_defaults to set common variables
Signed-off-by: Steve Kipisz <s-kipisz2@ti.com>
-rw-r--r-- | include/configs/am335x_evm.h | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h index b5ca267465e..fbfd59d663b 100644 --- a/include/configs/am335x_evm.h +++ b/include/configs/am335x_evm.h @@ -54,10 +54,11 @@ #ifndef CONFIG_SPL_BUILD #define CONFIG_EXTRA_ENV_SETTINGS \ "loadaddr=0x80200000\0" \ + "kloadaddr=0x80007fc0\0" \ "fdtaddr=0x80F80000\0" \ "fdt_high=0xffffffff\0" \ "rdaddr=0x81000000\0" \ - "bootfile=/boot/uImage\0" \ + "bootfile=uImage\0" \ "fdtfile=\0" \ "console=ttyO0,115200n8\0" \ "optargs=\0" \ @@ -79,10 +80,14 @@ "::off\0" \ "ramroot=/dev/ram0 rw ramdisk_size=65536 initrd=${rdaddr},64M\0" \ "ramrootfstype=ext2\0" \ - "mmcargs=setenv bootargs console=${console} " \ - "${optargs} " \ + "ip_method=none\0" \ + "bootargs_defaults=setenv bootargs " \ + "console=${console} " \ + "${optargs}\0" \ + "mmcargs=run bootargs_defaults;" \ + "setenv bootargs ${bootargs} " \ "root=${mmcroot} " \ - "rootfstype=${mmcrootfstype}\0" \ + "rootfstype=${mmcrootfstype} ip=${ip_method}\0" \ "nandargs=setenv bootargs console=${console} " \ "${optargs} " \ "root=${nandroot} " \ @@ -110,11 +115,11 @@ "root=${ramroot} " \ "rootfstype=${ramrootfstype}\0" \ "loadramdisk=fatload mmc ${mmcdev} ${rdaddr} ramdisk.gz\0" \ - "loaduimagefat=fatload mmc ${mmcdev} ${loadaddr} ${bootfile}\0" \ - "loaduimage=ext2load mmc ${mmcdev}:2 ${loadaddr} ${bootfile}\0" \ + "loaduimagefat=fatload mmc ${mmcdev} ${kloadaddr} ${bootfile}\0" \ + "loaduimage=ext2load mmc ${mmcdev}:2 ${kloadaddr} /boot/${bootfile}\0" \ "mmcboot=echo Booting from mmc ...; " \ "run mmcargs; " \ - "bootm ${loadaddr}\0" \ + "bootm ${kloadaddr}\0" \ "nandboot=echo Booting from nand ...; " \ "run nandargs; " \ "nand read ${loadaddr} ${nandsrcaddr} ${nandimgsize}; " \ @@ -154,8 +159,12 @@ "echo Running uenvcmd ...;" \ "run uenvcmd;" \ "fi;" \ - "if run loaduimage; then " \ + "if run loaduimagefat; then " \ + "run mmcboot;" \ + "elif run loaduimage; then " \ "run mmcboot;" \ + "else " \ + "echo Could not find ${bootfile} ;" \ "fi;" \ "else " \ "run nandboot;" \ |