Boot process on the Jetson TX2 with Jetpack 4.4.1

I am unclear as to how the boot process works on the Jetson TX2, specifically how does an SD card boot work. Reading through the flash script it looks like it flashes the board with U-boot then populates a rootfs on the eMMC that contains an extlinux.conf which says the rootfs is on the SD card. So then when the board would boot it first looks at that extlinux.conf and sees the real rootfs is on the SD card and then boots from that SD card. Is this understanding of the boot process correct? I am trying to understand this so I can boot a custom distro from an mSATA, USB, or SD card.

Also related to this, when I boot the board with no SD card plugged in and it is configured to check for the rootfs on the sdcard it says it can’t find the /dev/mmcblk1p1 and then puts me in a bash prompt. This makes sense but I am trying to understand where does this bash prompt come from and also where does this linux come from? Am I already past both cboot and uboot at this stage?

If you could dump the uart log from your board, you shall able to check the boot process.

https://elinux.org/Jetson/General_debug

The bash is initrd we provided. And the answer is yes, the cboot+uboot already done when you see the initrd.

As for your question in comment #1, this depends on the boot order of your uboot setting. Uboot has a scan order as mmc0/mmc1/usb… to find out which device has the extlinux.conf. If you move the sdcard order prior to the emmc and sdcard indeed has file system, then it will use the kernel from sdcard first.

Thanks for the response. So does uboot use that initrd and kernel image in the eMMC to boot into whatever device that is specified in the extlinux.conf?

I am also using the default uboot that comes from Nvidia.

For your question, I am just going to copy and paste what I said again.

, this depends on the boot order of your uboot setting. Uboot has a scan order as mmc0/mmc1/usb… to find out which device has the extlinux.conf.

Thus, uboot will use the kernel image from specific device which depends on the boot order.