[06/11] configs: omap5_common : Boot rootfs from sd card by default

Message ID 1415284132-6317-6-git-send-email-balbi@ti.com
State New
Headers show

Commit Message

Felipe Balbi Nov. 6, 2014, 2:28 p.m.
From: Franklin S Cooper Jr <fcooper@ti.com>

* Since the emmc isn't always programed trying to load the fs from the
  emmc causes boot failures/kernel panic.

* The current bootcmd is set to:
  bootcmd=run findfdt; run mmcboot;setenv mmcdev 1; setenv bootpart 1:2; \
  setenv mmcroot /dev/mmcblk0p2 rw; run mmcboot;

My guess is the env variables should be set so that sd card boot
(dt,kernel,fs) is the default and then fallback to emmc if it fails (no
sd card detected)

The current bootcmd attempts to set mmcroot to the sd card rootfs but
that code doesn't run due to mmcboot being ran early on.

Signed-off-by: Franklin Cooper Jr. <fcooper@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 include/configs/ti_omap5_common.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Tom Rini Nov. 10, 2014, 6:47 p.m. | #1
On Thu, Nov 06, 2014 at 08:28:47AM -0600, Felipe Balbi wrote:

> From: Franklin S Cooper Jr <fcooper@ti.com>
> 
> * Since the emmc isn't always programed trying to load the fs from the
>   emmc causes boot failures/kernel panic.
> 
> * The current bootcmd is set to:
>   bootcmd=run findfdt; run mmcboot;setenv mmcdev 1; setenv bootpart 1:2; \
>   setenv mmcroot /dev/mmcblk0p2 rw; run mmcboot;
> 
> My guess is the env variables should be set so that sd card boot
> (dt,kernel,fs) is the default and then fallback to emmc if it fails (no
> sd card detected)
> 
> The current bootcmd attempts to set mmcroot to the sd card rootfs but
> that code doesn't run due to mmcboot being ran early on.
> 
> Signed-off-by: Franklin Cooper Jr. <fcooper@ti.com>
> Signed-off-by: Felipe Balbi <balbi@ti.com>

Reviewed-by: Tom Rini <trini@ti.com>

Patch

diff --git a/include/configs/ti_omap5_common.h b/include/configs/ti_omap5_common.h
index 5b03fb1..de96d7d 100644
--- a/include/configs/ti_omap5_common.h
+++ b/include/configs/ti_omap5_common.h
@@ -78,7 +78,7 @@ 
 	"partitions=" PARTS_DEFAULT "\0" \
 	"optargs=\0" \
 	"mmcdev=0\0" \
-	"mmcroot=/dev/mmcblk1p2 rw\0" \
+	"mmcroot=/dev/mmcblk0p2 rw\0" \
 	"mmcrootfstype=ext4 rootwait\0" \
 	"mmcargs=setenv bootargs console=${console} " \
 		"${optargs} " \