
On Mon, Apr 25, 2022 at 3:47 PM Fabio Estevam festevam@denx.de wrote:
Hi Tim,
On 25/04/2022 16:41, Tim Harvey wrote:
Fabio,
Thanks - this at least allows me to boot on imx8mp-venice-gw74xx without needing to enable CONFIG_ENV_IS_NOWHERE.
Care to reply with your Tested-by?
Sure,
Tested-By: Tim Harvey tharvey@gateworks.com
I do however notice when I do so env is attempted to load from MMC dev 0 (CONFIG_ENV_IS_IN_MMC=y) - what controls the device number in this case as for this board, the emmc is dev 2.
That's a separate issue.
agreed it would be a separate issue... just curious if you knew where that was coming from. It certainly isn't a common behavior to boot via USB then expect 'saveenv' to save to a specific eMMC device.
I see that you replied to Peng's patch: "imx: dynamic setting mmcdev and mmcroot" and this is likely the cause for your env numbering problem.
That has nothing to do with the mmc device used for U-Boot env. Commit f342c9e381c0 ("imx: dynamic setting mmcdev and mmcroot") adds setting 'mmcroot=' if mmcautodetect=yes which seems to me like a completely inappropriate hack that assumes U-Boot's mmc device numbering matches the kernels device numbering (which has changed over time and is not a stable ABI). I believe you have been involved in discussions about that in the past as well regarding how to best tell the kernel what the root device is. Every discussion I have seen (and there have been many over the years) end up with the recommendation of using UUID.
Best regards,
Tim