Hi @nxp
I have custom board with imx8mp, Need to boot from SD card, if fails to boot from eMMc without changing switch, Please guide me to do this.
Hello,
You need to change the boot mode configuration according to required boot source, if you do not have a bootable imagen in selected boot source will cause board boot from serial download mode.
You can check the boot mode configuration in reference manual.
Best regards.
Hi @JorgeCas
We are currently using a setup where both the eMMC and SD card have been flashed with bootable images. The board is configured to boot from eMMC by default, and once deployed, it will be enclosed in a plastic casing with no access to the boot mode switches.
In this scenario, we would like to ensure that if the boot process from eMMC fails (e.g., due to a corrupted bootloader or missing files), the board should automatically attempt to boot from the SD card without requiring any manual intervention or change to the boot configuration switches.
Could you please advise on how this fallback mechanism can be implemented in U-Boot or the boot ROM? Specifically, we are looking for a method to configure the boot process to first try eMMC, and upon failure, seamlessly fall back to the SD card.
Thank you for your support.
iMX8MP already has a function called SD/MMC manufacture mode. When eMMC boot fails, it will switch to SD card boot. Usually this function is also used for mass production. When eMMC is empty, it will automatically switch to SD boot, start the program on the SD card, and burn the eMMC
Hello,
The boot flow cannot be changed and is like this:
If the board is able to enter to U-boot, you could try to change the boot flow with bootcmd environment variable.
Best regards.
JorgeCas,
Read SD/MMC manufacture mode chapter before drawing conclusions.