How to generate the SD card flashable image for TX2-NX

Hi,
I’m working on TX2-NX with R32.6.1 and try to generate the SD card flashable image. I tried to modify the jetson-disk-image-creator.sh, but there is no TX2 NX partition table for sdcard under the folder (bootloader\t186ref\cfg). So that jetson-disk-image-creator.sh can’t using nvptparser.py with correct flash.xml to create partitions.

Is therer have any other way to generate the TX2-NX SD card flashable image (ex: sd-blob.img) just like jetson-disk-image-creator.sh did for xaiver-nx devkit?

Thanks

hello jayjiang ,

you may workaround this by using --no-flash option to create system.img with flash.sh.
for example,
$ sudo ./flash.sh --no-flash jetson-xavier-nx-devkit-tx2-nx mmcblk0p1

Hi Jerry,
The image (system.img) generated from “sudo ./flash.sh --no-flash jetson-xavier-nx-devkit-tx2-nx mmcblk0p1” is not a bootable image beacause this image doesn’t contain the partition table. I need to know how to build the “SD card flashable” image and it can be flashed ​to an SD card with Etcher.

No rootfs is bootable in and of itself. It is just the file system. An SD card is not bootable without other content.

Boot content exists in the QSPI (for eMMC models it is the eMMC) memory. Earlier releases had part of the content on the SD card, more recent releases moved all of that to the QSPI.

It is possible though that the kernel or device tree can be retrieved either from the image’s “/boot”, or from a partition in QSPI. A given software release within the QSPI is generally the same for a range of releases, but more recent releases cannot use the QSPI of the older releases (I don’t remember which L4T version this split occurs at, perhaps someone here knows that answer).

In the case of content for the kernel or device tree coming from the rootfs it is the flash software command line which determines which kernel, device tree, and extlinux.conf is copied into the image’s “/boot” prior to generating the rootfs image.

The QSPI of the SD card model dev kits has its boot content flashed with JetPack/SDKM.

hello jayjiang,

I would like to confirm why you need to generate a SD image?

please refer to https://developer.nvidia.com/embedded/jetson-tx2-nx,
the storage of TX2 NX is the eMMC. it isn’t the SD card device.
thanks

Hi Jerry,

Due to our carrier board needs to support Xavier-NX/Nano/TX2-NX SOM (with EMMC) both and having SD slot on carrier board. We want to support two method about flash image. The first one is making device enter recovery mode and use nvmflash.sh to flash image to EMMC . And the other one is flashing image to SD card with Etcher, so that device don’t need to enter recovery mode. So we need to generate the SD card flashable image just like Xavier-NX and Nano. I’m not sure if NV can provide us the TX2-NX partition table like as “flash_l4t_t194_spi_sd_p3668.xml”, may be we can generate the bootable SD card image for TX2-NX.

Thanks

hello jayjiang,

we will not support generating SD image since TX2-NX is the eMMC device.
so, we only had the eMMC layout file, the script cannot use it to generate the SD image, there may have unexpected failures.

I’ll add a note on why you can’t just make equivalent SD card boot on the eMMC model…

During boot, prior to Linux loading, the boot content needs to differ if the (unsupported) SD card content is to be booted, and the SD card itself does not contain that difference. This difference is on non-rootfs eMMC content for the eMMC model. I think you’d have to alter eMMC ahead of time to have it detect and boot SD card content (which isn’t officially supported). The SD card or eMMC rootfs present (on eMMC models) is not the part which is “bootable” in the strictest definition.

Also, the cboot does not support extra sdcard slot. It only supports the internal storage sd. These two are different.

Which means even if you have a sdcard image, you still need kernel from emmc to help you mount the file system from your extra sd.

You won’t “boot from extra sd slot” without the help of your emmc.

Read this post to understand more about how “boot from external drive” works.

Hi all,
Many thanks for all quickly response. In general, these production SOMs (Nano,XavierNX, TX2-NX), their QSPI_NOR or sdmmc_boot partition including Boot Configuration Table, Boot binary, Boot Firmware,Bootloader device tree blob …etc, but the others such as kernel/rootfs were stored in sdcard/emmc_user partition.
I think I need to changing my question to:

  1. How to only flash the boot needed partitions (such as Boot Configuration Table, Boot binary, Boot Firmware, were defined in QSPI_NOR or sdmmc_boot Partition ) to EMMC on these production SOMs ?
  2. Making SD image that including kernel/rootfs…etc and make sure these SOMs can boot from SD.

Thanks

  1. What is your target module that you want to use? Nano and TX2-NX production module does not have QSPI. Every partition is over the emmc. We don’t suggest to change these partition layouts.

  2. There is no support for booting sdcard image from production module. Also, there is even no sdcard slot on these modules.

Hi Wayne,
Our targer module is Xaver-NX (P3668-0001), Nano (P3448-0002) and TX2-NX (P3636-0010).
From flash.xml , these SOMs have different device partitions,
For Xavier-NX: The boot device is QSPI ? If yes,

  • how to only flash that device type=“spi” related partitions (ex: BCT,mb1,spe-fw,cpu-bootloader…etc) to QSPI?
  • how to generate the SD image with device type = “sdmmc_user” related partitions (ex: primary_gpt, APP, kernel …etc) ? like

For Nano: The boot device is EMMC.

  • how to only flash that device type=“sdmmc” related partitions (ex: BCT, NVC, PT, TBC…etc) to EMMC ?
  • how to generate the SD image with device type = “sdmmc” related partitions (ex: GP1, APP, DTB, TOS, LNX…etc) ?

For TX2-NX:The boot device is EMMC.

  • how to only flash that device type=“sdmmc_boot” related partitions (ex: BCT, mb1, spe-fw, mb2…etc) to EMMC ?
  • how to generate the SD image with device type = “sdmmc_user” related partitions (ex: primary_gpt, APP, mts-bootpack, cpu-bootloader, secure-os, kerenl…etc) ?

If we can do that, we don’t need to flash full EMMC image on each SOM at factory side, we only need to flash partial images (ex: bootloader components ), and boot kernel / mount file system from SD card. So that we can using the same SD card to perform the factory testing and without flash full EMMC images.

Hi,

For Xavier-NX: The boot device is QSPI ? If yes,

  • how to only flash that device type=“spi” related partitions (ex: BCT,mb1,spe-fw,cpu-bootloader…etc) to QSPI?

There is a board config p3509-0000+p3668-0000-qspi.conf for this.

For the rest of modules, they cannot flash bootloader only.

If we can do that, we don’t need to flash full EMMC image on each SOM at factory side, we only need to flash partial images (ex: bootloader components ), and boot kernel / mount file system from SD card. So that we can using the same SD card to perform the factory testing and without flash full EMMC images.

There is no sdcard slot on such module. And our sdcard image tool does not support such module. Can you tell me what is your problem to understand this? We have been told you for for 3 times and you are still asking this sdcard question. Where will be this sdcard slot coming from?