Patchwork [U-Boot] am335x_evm.h: If mmcdev and bootpart switch to mmcdev 1, so should mmcroot.

mail settings
Submitter Robert P. J. Day
Date Sept. 9, 2013, 4:27 p.m.
Message ID <alpine.DEB.2.02.1309091221160.9061@oneiric>
Download mbox | patch
Permalink /patch/273616/
State Accepted
Delegated to: Tom Rini
Headers show


Robert P. J. Day - Sept. 9, 2013, 4:27 p.m.
If, in CONFIG_BOOTCOMMAND, the environment switches both the mmcdev
and bootpart variables to refer to MMC device 1, it would make sense
that the mmcroot env variable should switch to that device as well.

Signed-off-by: Robert P. J. Day <>


  i asked about this a while back and didn't hear any objections, so
i'll submit it as a patch. as you can see, if the first attempt to run
mmcboot fails, the environment is switched to refer to MMC device 1
(eMMC), and it would seem natural that mmcroot should follow along for
consistency. but i'm willing to be convinced otherwise.


diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
index 3de30fc..56a60da 100644
--- a/include/configs/am335x_evm.h
+++ b/include/configs/am335x_evm.h
@@ -170,6 +170,7 @@ 
 	"run mmcboot;" \
 	"setenv mmcdev 1; " \
 	"setenv bootpart 1:2; " \
+	"setenv mmcroot /dev/mmcblk1p2 ro; " \
 	"run mmcboot;" \
 	"run nandboot;"