Re: [U-Boot] [PATCH 2/6] pico-imx6ul: Use PARTUUID to specify the rootfs location

2017-11-14 Thread Fabio Estevam
On Tue, Nov 14, 2017 at 4:07 PM, Otavio Salvador
 wrote:
> From: Fabio Berton 
>
> Currently the rootfs location is passed via mmcblk number and using
> the UUID method to specify the rootfs location is a better approach
> working even if mmcblk number for the eMMM changes depending on the

s/eMMM/eMMC

With this fixed:

Reviewed-by: Fabio Estevam 
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH 2/6] pico-imx6ul: Use PARTUUID to specify the rootfs location

2017-11-14 Thread Otavio Salvador
From: Fabio Berton 

Currently the rootfs location is passed via mmcblk number and using
the UUID method to specify the rootfs location is a better approach
working even if mmcblk number for the eMMM changes depending on the
kernel versions.

Signed-off-by: Fabio Berton 
Signed-off-by: Otavio Salvador 
---

 configs/pico-imx6ul_defconfig | 1 +
 include/configs/pico-imx6ul.h | 6 +++---
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/configs/pico-imx6ul_defconfig b/configs/pico-imx6ul_defconfig
index 09b36ccb09..e00f9f34a3 100644
--- a/configs/pico-imx6ul_defconfig
+++ b/configs/pico-imx6ul_defconfig
@@ -13,6 +13,7 @@ CONFIG_CMD_DFU=y
 # CONFIG_CMD_FLASH is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_MMC=y
+CONFIG_CMD_PART=y
 CONFIG_CMD_USB=y
 CONFIG_CMD_USB_MASS_STORAGE=y
 CONFIG_CMD_DHCP=y
diff --git a/include/configs/pico-imx6ul.h b/include/configs/pico-imx6ul.h
index d4b29e3950..c775c32690 100644
--- a/include/configs/pico-imx6ul.h
+++ b/include/configs/pico-imx6ul.h
@@ -61,14 +61,15 @@
"fdt_addr=0x8300\0" \
"mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
"mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
-   "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
"mmcautodetect=yes\0" \
CONFIG_DFU_ENV_SETTINGS \
+   "finduuid=part uuid mmc 0:2 uuid\0" \
"mmcargs=setenv bootargs console=${console},${baudrate} " \
-   "root=${mmcroot}\0" \
+   "root=PARTUUID=${uuid} rootwait rw\0" \
"loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
"loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
"mmcboot=echo Booting from mmc ...; " \
+   "run finduuid; " \
"run mmcargs; " \
"if run loadfdt; then " \
"bootz ${loadaddr} - ${fdt_addr}; " \
@@ -147,6 +148,5 @@
 
 #define CONFIG_SYS_MMC_ENV_DEV 0
 #define CONFIG_SYS_MMC_ENV_PART0
-#define CONFIG_MMCROOT "/dev/mmcblk0p2"
 
 #endif /* __PICO_IMX6UL_CONFIG_H */
-- 
2.15.0

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot