This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM62A3-Q1: Using BootP Ethboot as a failover while using eMMC for Primary Boot

Greetings,

I have followed the instructions in the related post and I'm able to boot my board over Ethernet. What I would really like to do is have this available in the bootloader files for booting from eMMC or if there is perhaps a way to force secondary boot (i.e. RGMII boot mode) by issuing U-Boot environment commands, I think that would also be a viable solution. The only way I have found to get to the Backup Bootmode device is to remove the bootloader files (I assume corrupting them would also). I have tried running "bootcmd_dhcp" and using the tftp command in the u-boot environment but these don't function the same way as when built using the am62ax_evm_r5_ethboot_defconfig (looks like it is sending a BOOTP message to an "arm8", which I haven't found any support/info for booting this way for the AM62A). My custom board uses only the eMMC as a storage/boot device and only has access through Ethernet unless it is disassembled and a special adapter board is connected so having this functionality for failover is highly desirable (along with using U-Boot's netconsole tool).

Is there a known way to use boot over ethernet while having eMMC set as the Primary boot device/media? 

Thanks in advanced for the assistance.

  • Hi Steve,

    As you mention, you can use the following: Primary Bootmode => eMMC, Backup Bootmode => Ethernet

    To boot from the Ethernet as a backup boot, you must erase the R5 SPL (tiboot3.bin) from the eMMC so that ROM fails to boot from primary bootmode and fallback to booting from backup boot.

    Have you tried this approach and not working?

    Regards,

    Prashant

  • Yes, I have tried that and it works but erasing my bootloader file(s) from the eMMC boot partition on detecting a failure really isn't a good solution on a product, wouldn't you agree? So, if there is a way to use a U-boot command (i.e. something like the "dhcp", "tftp", or "run bootcmd_dhcp" since none of these do this) to make it work like using Ethernet as the Primary boot mode is highly preferable or forcing it in to the backup bootmode somehow.

    Regards,

    Steve T

  • Hi Steve,

    The ROM support for Primary and Backup boot is to allow redundancy in the system and not to give a choice between them. So, the ROM will always try to boot SBL/SPL in the order:

    1) Primary offset from Primary Boot Media

    2) If supported, redundant offset from Primary Boot Media

    3) Backup Boot Media.

    Any other design surrounding the usage of Primary and Backup boot is basically a hack.

    => If my understanding is correct, what you would like to have is an option to choose between Primary and Backup Boot which isn't supported by the ROM.

    => If you are using Ethernet just for updates, you can use the U-Boot booted from eMMC to receive the images over Ethernet and flash them. If you have a different use-case, please help me understand so I can better assist you.

    Regards,

    Prashant

  • Hello Prashant,

    I've been giving your last reply lots of thought and research, as I still don't feel like I have a comprehensive understanding of how all of the boot functionality works (specifically for the AM62Ax) despite reading the SDK online documentation, TI Academy, TRM, and related posts that I could find on the E2E forums. Your reply did help me understand more about the ROM and the boot images though, Also, about the redundant offset (as further detailed in this post: e2e_link.). My inquiries mostly stem from the fact that due to my product requirements, I don't have serial console access to the U-Boot console typically so it is challenging to detect any kind of boot failure with the default functionality. I'm therefore interested in getting my device into a state that I can at least have some way to observe that it is stuck booting and access it for repair.

    Do you know if there is a currently supported way for the AM62Ax to load a Linux environment over Ethernet using a U-boot command (perhaps using the "dhcp" or "tftp" commands in U-Boot or one of the other environment variable bootcmds) when built with "am62ax_evm_a53_defconfig" and "am62ax_evm_r5_defconfig"?

    Also, if you could provide information on how use Ethernet to receive images and flash them, that would be appreciated.

    Best Regards,
    Steve T

  • Hello Steve,

    Do you know if there is a currently supported way for the AM62Ax to load a Linux environment over Ethernet using a U-boot command

    You can create a Linux Kernel with Initramfs and boot it over Ethernet

    (1) [FAQ] Linux: How to boot Sitara AM3x/AM4x/AM6x devices from initramfs (.cpio Archive, RAM Disk) - Processors forum - Processors - TI E2E support forums

    Also, if you could provide information on how use Ethernet to receive images and flash them, that would be appreciated.

    The "tftp" command can be used to receive the images and "mmc write" can be used to flash them.

    => mmc dev 0 1
    switch to partitions #1, OK
    mmc0(part 1) is current device
    => tftp $loadaddr tiboot3.bin
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server XX.XX.XX.XX; our IP address is XX.XX.XX.XX; sending through gateway XX.XX.XX.XX
    Filename 'tiboot3.bin'.
    Load address: 0x82000000
    Loading: ##################################################  301.3 KiB
             3.2 MiB/s
    done
    Bytes transferred = 308531 (4b533 hex)
    => mmc write $loadaddr 0x0 0x400
    
    MMC write: dev # 0, block # 0, count 1024 ... 1024 blocks written: OK
    => tftp $loadaddr tispl.bin
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server XX.XX.XX.XX; our IP address is XX.XX.XX.XX; sending through gateway XX.XX.XX.XX
    Filename 'tispl.bin'.
    Load address: 0x82000000
    Loading: ##################################################  1.3 MiB
             4.3 MiB/s
    done
    Bytes transferred = 1334439 (145ca7 hex)
    => mmc write $loadaddr 0x400 0x1400
    
    MMC write: dev # 0, block # 1024, count 5120 ... 5120 blocks written: OK
    => tftp $loadaddr u-boot.img
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server XX.XX.XX.XX; our IP address is XX.XX.XX.XX; sending through gateway XX.XX.XX.XX
    Filename 'u-boot.img'.
    Load address: 0x82000000
    Loading: ##################################################  1.1 MiB
             3.7 MiB/s
    done
    Bytes transferred = 1104155 (10d91b hex)
    => mmc write $loadaddr 0x1400 0x2000
    
    MMC write: dev # 0, block # 5120, count 8192 ... 8192 blocks written: OK
    => 

    Regards,

    Prashant