# Massflash QSPI to prod SoM

**URL:** <https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899>\
**Category:** Jetson Xavier NX\
**Tags:** reflash\
**Created:** [February 7, 2023, 6:20am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899 "2023-02-07T06:20:45Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 6:20am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/1 "2023-02-07T06:20:45Z")

</div>

I would like to know what the quickest possible way is to flash just the QSPI inside the Xavier NX production SoM.

The use case is very simple. I would like to massflash them as quickly and simply as possible. The only requirement is the SoM’s are capable of booting a Jetpack 5.1 NVMe disk.

So far I have had partial success testing two simultaneous flashes as follows:

```auto
sudo BOARDID=3668 BOARDSKU=0001 FAB=100 ./tools/kernel_flash/l4t_initrd_flash.sh --no-flash --massflash 3 --network usb0 jetson-xavier-nx-devkit-emmc nvme0n1p1

sudo ./tools/kernel_flash/l4t_initrd_flash.sh --flash-only --massflash 3 --network usb0 --keep

```

Tried a second time with that last call with `--reuse` instead of `--keep`. Not sure that this made it any faster.

One of the devices seems to complete in under 5 minutes, however only one of my devices actually flashes. the other one seems to be stuck on

```auto
Waiting for device to expose ssh ...RTNETLINK answers: File exists
...RTNETLINK answers: File exists
RTNETLINK answers: File exists
Waiting for device to expose ssh .............

```

and times out. I note that lsusb shows `0955:7035` which based on this topic [Difference between device 0955:7035 and 0955:7e19?](https://forums.developer.nvidia.com/t/difference-between-device-0955-7035-and-0955-7e19/200234) means it waiting for a communication in the middle of the initrd process.

I will try some other USB ports and USB cables, but in the meantime I want to ask:

**What is the most time efficient way to prepare SoMs? Is there a backup/restore feature we can use that could be faster? Is massflash (kind of misbehaving for me right now testing just two devices) the only way to run more than one flash at a time per computer?**

Previously with Jetpack 4.x I did not have ssh timeout problems with massflash. Are there other additional logs I can turn on to understand why it times out? Would obtaining serial console output help?

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 6:32am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/3 "2023-02-07T06:32:25Z")

</div>

I now note the following:

Both this “failed” flash unit (that ended up in 0955:7035 state, Timeout during `Waiting for device to expose ssh`) and the unit that successfully completed the massflash procedure actually boot up by themselves with a UEFI compiled from Jan 24 2023 and direct boot up to a Bash-5.0 root shell. This indicates for me that I am not actually interested in any of the steps that take several minutes within this `Step 3: Start the flashing process`.

It looks to me that the `Step 2: Boot the device with flash initrd image` step:

```auto
****************************************************
* *
* Step 2: Boot the device with flash initrd image *
* *
****************************************************
/home/user/dir/Linux_for_Tegra/temp_initrdflash/bootloader1 /home/user/dir/Linux_for_Tegra
./tegraflash.py --bl nvtboot_recovery_cpu_t194_sigheader.bin.encrypt --bct br_bct_BR.bct --securedev --bldtb tegra194-p3668-0001-p3509-0000.dtb --applet rcm_2_encrypt.rcm --applet_softfuse rcm_1_encrypt.rcm --cmd "rcmboot" --cfg secureflash.xml --chip 0x19 --mb1_bct mb1_bct_MB1_sigheader.bct.encrypt --mem_bct mem_rcm_sigheader.bct.encrypt --mb1_cold_boot_bct mb1_cold_boot_bct_MB1_sigheader.bct.encrypt --mem_bct_cold_boot mem_coldboot_sigheader.bct.encrypt --bins "mb2_bootloader nvtbo
ot_recovery_t194_sigheader.bin.encrypt; mts_preboot preboot_c10_prod_cr_sigheader.bin.encrypt; mts_mce mce_c10_prod_cr_sigheader.bin.encrypt; mts_proper mts_c10_prod_cr_sigheader.bin.encrypt; bpmp_fw bpmp-2_t194_sigheader.bin.encrypt; bpmp_fw_dtb tegra194-a02-bpmp-p3668-a00_lz4_sigheader.dtb.encrypt; spe_fw spe_t194_sigheader.bin.encrypt; tos tos-optee_t194_sigheader.img.encrypt; eks eks_t194_sigheader.img.encrypt; kernel boot1.img; kernel_dtb kernel_tegra194-p3668-0001-p3509-0000.dtb;
bootloader_dtb tegra194-p3668-0001-p3509-0000_sigheader.dtb.encrypt" --secondary_gpt_backup --bct_backup --boot_chain A --instance 3-6
Welcome to Tegra Flash
version 1.0.0
Type ? or help for help and q or quit to exit
Use ! to execute system commands

 Entering RCM boot

[0.0000] rcm boot with presigned binaries
[0.0000] Boot Rom communication
[0.0016] tegrarcm_v2 --instance 3-6 --chip 0x19 0 --rcm rcm_1_encrypt.rcm --rcm rcm_2_encrypt.rcm
[0.0021] BR_CID: 0x88021911640600831400000011ff8200
[0.0147] Boot Rom communication completed
[2.0411] tegrarcm_v2 --instance 3-6 --isapplet
[2.0423] Applet version 01.00.0000
[2.0748] Sending BCTs
[2.0766] tegrarcm_v2 --instance 3-6 --download bct_bootrom br_bct_BR.bct --download bct_mb1 mb1_bct_MB1_sigheader.bct.encrypt --download bct_mem mem_rcm_sigheader.bct.encrypt
[2.0772] Applet version 01.00.0000
[2.1017] Sending bct_bootrom
[2.1017] [................................................] 100%
[2.1027] Sending bct_mb1
[2.1076] [................................................] 100%
[2.1110] Sending bct_mem
[2.1587] [................................................] 100%
[2.1944] Generating blob
[2.1973] tegrahost_v2 --chip 0x19 --generateblob blob.xml blob.bin
[2.1983] number of images in blob are 13
[2.1988] blobsize is 62868781
[2.1990] Added binary blob_nvtboot_recovery_cpu_t194_sigheader.bin.encrypt of size 233040
[2.2184] Added binary blob_nvtboot_recovery_t194_sigheader.bin.encrypt of size 206016
[2.2187] Added binary blob_preboot_c10_prod_cr_sigheader.bin.encrypt of size 24016
[2.2190] Added binary blob_mce_c10_prod_cr_sigheader.bin.encrypt of size 145184
[2.2193] Added binary blob_mts_c10_prod_cr_sigheader.bin.encrypt of size 3430416
[2.2210] Added binary blob_bpmp-2_t194_sigheader.bin.encrypt of size 1007392
[2.2219] Added binary blob_tegra194-a02-bpmp-p3668-a00_lz4_sigheader.dtb.encrypt of size 36176
[2.2223] Added binary blob_spe_t194_sigheader.bin.encrypt of size 95232
[2.2225] Added binary blob_tos-optee_t194_sigheader.img.encrypt of size 914992
[2.2228] Added binary blob_eks_t194_sigheader.img.encrypt of size 5136
[2.2231] Added binary blob_boot1.img of size 56109056
[2.2598] Added binary blob_kernel_tegra194-p3668-0001-p3509-0000.dtb of size 323861
[2.2662] Added binary blob_tegra194-p3668-0001-p3509-0000_sigheader.dtb.encrypt of size 338048
[2.2977] Sending bootloader and pre-requisite binaries
[2.2998] tegrarcm_v2 --instance 3-6 --download blob blob.bin
[2.3005] Applet version 01.00.0000
[2.3199] Sending blob
[2.3200] [] 001%^M[2.3200] [.] 003%^M[2.3200] [..] 005%^M[2.3200] [...] 006%^M[2.3200] [....] 008%^M[2.3200] [.....] 010%^M[2.3200] [.....] 011%^M[
   2.3200 ] [......] 013%^M[2.3200] [.......] 015%^M[2.3200] [........] 016%^M[2.3200] [.........] 018%^M[2.3200] [..........] 020%^M[2.3200] [..........] 021%^M[2.3200] [...........] 023%^M[
  2.3200 ] [............] 025%^M[2.3200] [.............]
<snip>
[..........................................] 085%^M[2.3200] [...........................................] 086%^M[2.3200] [............................................] 088%^M[2.3200] [.............................................] 090%^M[2.3200] [.............................................] 091%^M[2.3200] [..............................................] 093%^M[ 2.32
00 ] [...............................................] 095%^M[2.3200] [................................................] 096%^M[2.3200] [................................................] 098%^M[2.3200] [................................................] 100%
[10.7446] tegrarcm_v2 --instance 3-6 --boot rcm
[10.7456] Applet version 01.00.0000
[10.7686] RCM-boot started

```

Whatever this did within 10 seconds it looks like is all I need to set up the bootloader so that these things can boot to a Jetpack 5.1 NVMe and allow our product to function.

I am sure we can hack the scripts to stop before step 3 or cause step 3 to exit immediately, but I wonder if there is a proper workflow for this? Either way, I am extremely happy with a 10 second turnaround on this and this result will make many people very happy.

---

<div class="post-metadata">

**Author:** ![WayneWWW](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/waynewww/32/14043_2.png) [@WayneWWW](https://forums.developer.nvidia.com/u/WayneWWW)\
**Post date:** [February 7, 2023, 6:33am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/4 "2023-02-07T06:33:40Z")

</div>

Hi,

Do you mean you want a fast way to flash QSPI only in massflash and you don’t want to flash emmc?

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 6:35am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/5 "2023-02-07T06:35:05Z")

</div>

Exactly right. Yes the eMMC flash appears to take a very long time compared to this initial step. Even though I was able to configure this thing to not prepare a full OS for the eMMC, it still takes like 5 minutes.

Based on my most recent test result, it looks like the NVMe already comes with the necessary partitions. So we want to figure out the official way to flash just the bootloader to the SoM. Massively cloning our NVMe will get us the rest of the way.

---

<div class="post-metadata">

**Author:** ![WayneWWW](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/waynewww/32/14043_2.png) [@WayneWWW](https://forums.developer.nvidia.com/u/WayneWWW)\
**Post date:** [February 7, 2023, 6:36am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/6 "2023-02-07T06:36:42Z")

</div>

Try to use p3509-0000+p3668-0000-qspi in flash command instead of p3509-0000+p3668-0001-qspi-emmc which is actually jetson-xavier-nx-devkit-emmc.

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 6:38am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/7 "2023-02-07T06:38:17Z")

</div>

Thank you. I have seen a `p3509-0000+p3668-0000-qspi.conf` file, but documentation does not ever mention it. Since it is in the BSP root dir I will attempt to use this string instead of `jetson-xavier-nx-devkit-emmc`

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 6:48am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/8 "2023-02-07T06:48:47Z")

</div>

I have run the commands again but it looks to be `waiting for device to expose ssh` again in step 3. With one of them timing out. So this is not really any change from before.

It seems I should try each time with a cleanly unpacked BSP directory. I will script it up and transition to doing this from Docker once I get it working. But so far it’s encouraging, because specifying `p3509-0000+p3668-0000-qspi` for the board-name to the first command did not fail. It still generated a whole mfi dir packed with full rootfs, which clearly is not necessary, but I’ll worry about that later.

---

<div class="post-metadata">

**Author:** ![WayneWWW](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/waynewww/32/14043_2.png) [@WayneWWW](https://forums.developer.nvidia.com/u/WayneWWW)\
**Post date:** [February 7, 2023, 6:59am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/10 "2023-02-07T06:59:20Z")

</div>

For that flashed but failure board, could you check if they do have updated bootloader by checking the boot uart log?

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 9:26pm UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/11 "2023-02-07T21:26:13Z")

</div>

I do have a CP2102 uart/usb adapter here but I’m trying to get something known and working off of `p3509-0000+p3668-0000-qspi` initrd massflash first. Will investigate this if I can’t make this work right.

In the worst case, I can use other methods to flash SoMs with an old jetpack version, to “reset” and evaluate the process.

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 9:39pm UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/12 "2023-02-07T21:39:19Z")

</div>

I made a clean BSP directory and using `p3509-0000+p3668-0000-qspi` is not changing the behavior of the massflash procedure; it’s still flashing emmc during Step 3.

```auto
[10.8146] tegrarcm_v2 --instance 1-2.4 --boot rcm
[10.8159] Applet version 01.00.0000
[10.8458] RCM-boot started

/home/user/dir/2023-02-07/Linux_for_Tegra
***************************************
* *
* Step 3: Start the flashing process *
* *
***************************************
Waiting for target to boot-up...
Waiting for target to boot-up...
Waiting for target to boot-up...
Waiting for target to boot-up...
Waiting for target to boot-up...
Waiting for device to expose ssh ......RTNETLINK answers: File exists
RTNETLINK answers: File exists
Waiting for device to expose ssh ...Run command: flash on fc00:1:1:0::2
SSH ready
blockdev: cannot open /dev/mmcblk0boot0: No such file or directory
[0]: l4t_flash_from_kernel: Starting to create gpt for emmc
Active index file is /mnt/internal/flash.idx
Number of lines is 42
max_index=41
[2]: l4t_flash_from_kernel: Successfully create gpt for emmc
[2]: l4t_flash_from_kernel: Starting to flash to emmc
Flash index file is /mnt/internal/flash.idx
Number of lines is 42
max_index=41
Active index file is /mnt/internal/flash.idx
Number of lines is 42
max_index=41
[2]: l4t_flash_from_kernel: Starting to flash to qspi
^MErasing 64 Kibyte @ 0 -- 0 % complete [4]: l4t_flash_from_kernel: Successfully flash the emmc

```

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 9:58pm UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/13 "2023-02-07T21:58:55Z")

</div>

flashing `p3509-0000+p3668-0000-qspi` doesn’t work. They always just come up in `0955:7e19` DFU mode even after inserting nvme with jetpack 5.1 on it. setting up serial console now…

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 7, 2023, 10:18pm UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/14 "2023-02-07T22:18:41Z")

</div>

```auto
Welcome to minicom 2.7.1

OPTIONS: I18n 
Compiled on Dec 23 2019, 02:06:26.
Port /dev/ttyUSB0, 17:14:40

Press CTRL-A Z for help on special keys

��
[0000.025] W> RATCHET: MB1 binary ratchet value 4 is larger than ratchet level 2 from HW fuses.
[0000.033] I> MB1 (prd-version: 2.5.0.0-t194-41334769-d9272b5a)
[0000.039] I> Boot-mode: Coldboot
[0000.042] I> Platform: Silicon
[0000.044] I> Chip revision : A02P
[0000.047] I> Bootrom patch version : 15 (correctly patched)
[0000.053] I> ATE fuse revision : 0x200
[0000.056] I> Ram repair fuse : 0x0
[0000.059] I> Ram Code : 0x0
[0000.062] I> rst_source: 0x0, rst_level: 0x0
[0000.067] I> Boot-device: QSPI (instance: 0)
[0000.071] I> Qspi flash params source = brbct
[0000.075] I> Qspi clock source : pllp
[0000.078] I> Qspi-0 initialized successfully
[0000.082] I> Boot chain mechanism: A/B
[0000.085] I> Current Boot-Chain Slot: 0
[0000.089] I> BR-BCT Boot-Chain: 0, status: 0. update flag: 0
[0000.094] I> Qspi flash params source = brbct
[0000.101] W> PROD_CONFIG: device prod data is empty in MB1 BCT.
[0000.108] I> Temperature = 21500
[0000.111] W> Skipping boost for clk: BPMP_CPU_NIC
[0000.115] W> Skipping boost for clk: BPMP_APB
[0000.119] W> Skipping boost for clk: AXI_CBB
[0000.123] W> Skipping boost for clk: AON_CPU_NIC
[0000.127] W> Skipping boost for clk: CAN1
[0000.131] W> Skipping boost for clk: CAN2
[0000.135] I> Boot-device: QSPI (instance: 0)
[0000.139] I> Qspi flash params source = mb1bct
[0000.143] I> Qspi clock source : pllc_out0
[0000.147] I> Qspi-0 reinitialized
[0000.150] I> Qspi flash params source = mb1bct
[0000.163] I> Non-ECC region[0]: Start:0x80000000, End:0x100000000
[0000.170] W> Thermal config not found in BCT
[0000.178] W> MEMIO rail config not found in BCT
[0000.188] I> Qspi flash params source = mb1bct
[0000.202] I> Qspi flash params source = mb1bct
[0000.236] I> Qspi flash params source = mb1bct
[0000.799] I> Qspi flash params source = mb1bct
[0000.816] I> Qspi flash params source = mb1bct
[0000.855] W> Platform config not found in BCT
[0000.882] I> Qspi flash params source = mb1bct
[0000.908] I> MB1 done

����main enter
SPE VERSION #: R01.00.18 Created: Jan 29 2021 @ 14:18:27
HW Function test
Start Scheduler.
in late init
��
  [0000.917] I> Welcome to MB2(TBoot-BPMP) (version: default.t194-mobile-78ae5a2a)
[0000.918] I> DMA Heap @ [0x526fa000 - 0x52ffa000]
[0000.918] I> Default Heap @ [0xd486400 - 0xd48a400]
[0000.919] E> DEVICE_PROD: Invalid value data = 70020000, size = 0.
[0000.925] W> device prod register failed
[0000.928] I> gpio framework initialized
[0000.932] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio' driver
[0000.939] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio-aon' driver
[0000.947] I> sdcard_params [0, 55, 0, 50] in mb1_bct
[0000.952] I> Boot_device: QSPI_FLASH instance: 0
[0000.956] I> qspi flash-0 params source = boot args
[0000.962] I> QSPI-0l initialized successfully
[0000.972] I> Found 41 partitions in QSPI_FLASH (instance 0)
[0000.974] I> Active Boot chain : 0
[0001.655] I> Relocating BR-BCT
[0001.657] > DEVICE_PROD: device prod is not initialized.
[0001.968] I> Relocating OP-TEE dtb from: 0x6bfff240 to 0x70050000, size: 1008
[0001.969] I> [0] START: 0x80000000, SIZE: 0x2f000000
[0001.969] I> [1] START: 0xaf010000, SIZE: 0x18bf0000
[0001.970] I> [2] START: 0xc7d00000, SIZE: 0xc0000
[0001.970] I> [3] START: 0xca000000, SIZE: 0x800000
[0001.971] I> dram_block larger than 80000000
[0001.973] I> [4] START: 0x100000000, SIZE: 0x180000000
[0001.985] I> Setting NS memory ranges to OP-TEE dtb finished.
[0001.988] I> found decompressor handler: lz4
[0002.216] I> EKB detected (length: 0x410) @ VA:0x526ff400
[0002.218] I> Setting EKB blob info to OPTEE dtb finished.
��NOTICE: BL31: v2.6(release):6363e7382
NOTICE: BL31: Built : 15:09:29, Jan 24 2023
I/TC: 
��
  bpmp: init
bpmp: tag is 128431eec76692047e1ac1ebc0392266
sku_dt_init: not sku 0x00
clk_early initialized
��I/T��mail_early initialized
��C��fuse initialized
hwwdt initialized
��: Non��t194_ec_get_ec_list: found 45 ecs
��-secure ex��ec initialized
��t��vmon_setup_monitors: found 3 monitors
vmon initialized
��ern��adc initialized
fmon_populate_monitors: found 73 monitors
��al DT found
��fmon initialized
mc initialized
reset initialized
nvhs initialized
uphy_early initialized
emc_early initialized
392 clocks registered
clk initialized
io_dpd initialized
thermal initialized
thermal_mrq initialized
i2c initialized
vrmon_dt_init: vrmon node not found
vrmon_chk_boot_state: found 0 rail monitors
vrmon initialized
regulator initialized
avfs_clk_platform initialized
soctherm initialized
aotag initialized
powergate initialized
dvs initialized
pm initialized
suspend initialized
pg_late initialized
pg_mrq_init initialized
strap initialized
nvl initialized
emc initialized
emc_mrq initialized
clk_dt initialized
tj_init initialized
uphy_dt initialized
uphy_mrq initialized
uphy initialized
ec_swd_poll_start: 281 reg polling start w period 47 ms
ec_late initialized
hwwdt_late initialized
reset_mrq initialized
ec_mrq initialized
fmon_mrq initialized
clk_mrq initialized
avfs_mrq initialized
mail_mrq initialized
i2c_mrq initialized
tag_mrq initialized
console_mrq initialized
mrq initialized
clk_sync_fmon_post initialized
��I/TC: OP-TEE version: 3.19 (gcc version 9.3.0 (Buildroot 2020.08)) #2 Tu��clk_dt_late initialized
noc_late initialized
��e��pm_post initialized
dbells initialized
�� Ja��dmce initialized
��n��cvc initialized
�� 24 23:20:42��avfs_clk_mach_post initialized
�� UTC��avfs_clk_platform_post initialized
�� 20��cvc_late initialized
regulator_post initialized
��23 a��rm initialized
console_late initialized
clk_dt_post initialized
mc_reg initialized
��arch64
I/TC: WARNING:��pg_post initialized
profile initialized
fuse_late initialized
extras_post initialized
bpmp: init complete
entering main console loop
] �� This OP-TEE configuration might be insecure!
I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
I/TC: Primary CPU initializing
I/TC: Primary CPU switching to normal world boot
��
  [0002.837] I> Welcome to NVDisp-Init
[0002.837] I> NVDisp-Init version: t194-709c0123
[0002.837] I> CPU-BL Params @ 0xca020000
[0002.837] I> 0) Base:0x00000000 Size:0x00000000
[0002.838] I> 1) Base:0xc8300000 Size:0x00100000
[0002.838] I> 2) Base:0xc9800000 Size:0x00200000
[0002.838] I> 3) Base:0xc8600000 Size:0x00200000
[0002.841] I> 4) Base:0xc8200000 Size:0x00100000
[0002.845] I> 5) Base:0xc8100000 Size:0x00100000
[0002.850] I> 6) Base:0xc9400000 Size:0x00400000
[0002.854] I> 7) Base:0xc9000000 Size:0x00400000
[0002.859] I> 8) Base:0xc8000000 Size:0x00100000
[0002.863] I> 9) Base:0xc7f00000 Size:0x00100000
[0002.868] I> 10) Base:0xca800000 Size:0x00800000
[0002.872] I> 11) Base:0x40000000 Size:0x00040000
[0002.877] I> 12) Base:0xc7e00000 Size:0x00100000
[0002.881] I> 13) Base:0x40046000 Size:0x00002000
[0002.886] I> 14) Base:0x40048000 Size:0x00002000
[0002.890] I> 15) Base:0xaf000000 Size:0x00004000
[0002.895] I> 16) Base:0x4004a000 Size:0x00002000
[0002.899] I> 17) Base:0xc7c00000 Size:0x00100000
[0002.903] I> 18) Base:0x4004c000 Size:0x00002000
[0002.908] I> 19) Base:0xc9a00000 Size:0x00600000
[0002.912] I> 20) Base:0x4004e000 Size:0x00002000
[0002.917] I> 21) Base:0xc7dc0000 Size:0x0000c000
[0002.921] I> 22) Base:0x00000000 Size:0x00000000
[0002.926] I> 23) Base:0xc7de0000 Size:0x00020000
[0002.930] I> 24) Base:0xcc000000 Size:0x02000000
[0002.935] I> 25) Base:0x40050000 Size:0x00002000
[0002.939] I> 26) Base:0x40040000 Size:0x00006000
[0002.944] I> 27) Base:0xc8c00000 Size:0x00400000
[0002.948] I> 28) Base:0xc8400000 Size:0x00200000
[0002.953] I> 29) Base:0xc8800000 Size:0x00400000
[0002.957] I> 30) Base:0xc7dd0000 Size:0x00010000
[0002.961] I> 31) Base:0x00000000 Size:0x00000000
[0002.966] I> 32) Base:0xf8000000 Size:0x08000000
[0002.970] I> 33) Base:0xce000000 Size:0x2a000000
[0002.975] I> 34) Base:0xcb000000 Size:0x01000000
[0002.979] I> 35) Base:0xae000000 Size:0x01000000
[0002.984] I> 36) Base:0xa0000000 Size:0x0e000000
[0002.988] I> 37) Base:0xca000000 Size:0x00800000
[0002.993] I> 38) Base:0x80000000 Size:0x20000000
[0002.997] I> 39) Base:0xb0000000 Size:0x08000000
[0003.002] I> 40) Base:0x00000000 Size:0x00000000
[0003.006] I> 41) Base:0x00000000 Size:0x00000000
[0003.011] I> 42) Base:0x00000000 Size:0x00000000
[0003.015] I> 43) Base:0x00000000 Size:0x00000000
[0003.019] I> 44) Base:0x00000000 Size:0x00000000
[0003.024] I> 45) Base:0x00000000 Size:0x00000000
[0003.028] GIC-SPI Target CPU: 0
[0003.031] Interrupts Init done
[0003.034] calling constructors
[0003.037] initializing heap
[0003.040] I> Heap: [0xa0960000 ... 0xadf00000]
[0003.044] initializing threads
[0003.047] initializing timers
[0003.050] creating bootstrap completion thread
[0003.054] top of bootstrap2()
[0003.057] CPU: MIDR: 0x4E0F0040, MPIDR: 0x80000000
[0003.061] initializing platform
[0003.064] E> DEVICE_PROD: Invalid value data = 0, size = 0.
[0003.070] W> device prod register failed
[0003.074] I> Bl_dtb @0xadf00000
[0003.077] I> gpio framework initialized
[0003.087] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio' driver
[0003.092] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio-aon' driver
[0003.099] I> fixed regulator driver initialized
[0003.114] I> register 'maxim' power off handle
[0003.117] I> virtual i2c enabled
[0003.117] I> registered 'maxim,max20024' pmic
[0003.118] I> tegrabl_gpio_driver_register: register 'max20024-gpio' driver
[0003.118] I> Boot-device: QSPI
[0003.121] I> Boot_device: QSPI_FLASH instance: 0
[0003.125] I> configure_qspi_clk: qparams clk_src = 5, clk_div = 0, clk_src_freq = 800000000, interface_freq = 50000000
[0003.136] I> configure_qspi_clk: FORCING INTERFACE_FREQ TO 133000000!!
[0003.143] I> QSPI source rate = 204000 Khz
[0003.146] I> Requested rate for QSPI clock = 34000 Khz
[0003.151] I> BPMP-set rate for QSPI clk = 34000 Khz
[0003.156] I> tx_clk_tap_delay : 0
[0003.159] I> rx_clk_tap_delay : 16
[0003.162] I> QSPI Flash Size = 32 MB
[0003.170] I> Qspi initialized successfully
[0003.171] I> qspi flash-0 params source = boot args
[0003.175] W> No board IDs available
[0003.178] E> Failed to get board id info!
[0003.186] I> Found 41 partitions in QSPI_FLASH (instance 0)
[0003.204] I> regulator 'vdd-hdmi-5v0' already enabled
[0003.211] I> regulator 'vdd-hdmi-5v0' already enabled
[0003.212] I> hdmi cable connected
[0003.218] W> set volts not configured for 'vdd-1v0'
[0003.225] W> set volts not configured for 'vdd-1v8-hs'
[0003.225] I> retrieved tmds range from prod_list_hdmi_soc
[0003.227] E> cannot find any other nvdisp nodes
[0003.243] I> edid read success
[0003.256] I> edid read success
[0003.256] I> width = 640, height = 480, frequency = 25174825
[0003.256] I> width = 640, height = 480, frequency = 25174825
[0003.257] I> width = 640, height = 480, frequency = 25174825
[0003.257] I> width = 640, height = 480, frequency = 25174825
[0003.258] I> width = 1024, height = 768, frequency = 65000000
[0003.261] I> width = 1024, height = 768, frequency = 65000000
[0003.267] I> width = 1024, height = 768, frequency = 65000000
[0003.272] I> width = 2560, height = 1440, frequency = 580080000
[0003.278] I> width = 1920, height = 1080, frequency = 148500000
[0003.284] I> width = 1920, height = 1080, frequency = 148351648
[0003.290] I> width = 1920, height = 1080, frequency = 148351648
[0003.295] I> width = 1280, height = 720, frequency = 74175824
[0003.301] I> width = 1280, height = 720, frequency = 74175824
[0003.307] I> width = 720, height = 480, frequency = 26973026
[0003.312] I> width = 720, height = 576, frequency = 26973026
[0003.318] I> Best mode Width = 1920, Height = 1080, freq = 148351648
[0003.329] I> hdmi_enable, starting HDMI initialisation
[0003.334] I> hdmi_enable, HDMI initialisation complete
[0003.343] initializing target
[0003.344] calling apps_init()
[0003.345] starting app kernel_boot_app
[0003.346] I> Kernel type = Normal

Jetson UEFI firmware (version 2.1-32413640 built on 2023-01-24T23:12:27+00:00)

ASSERT [DxeCore] /out/nvidia/bootloader/uefi/Jetson_RELEASE/edk2/MdeModulePkg/Core/Dxe/DxeMain/DxeMain.c(562): !(((INTN)(RETURN_STATUS)(Statu)

Resetting the system in 5 seconds.
����Shutdown state requested 1
Rebooting system ...
��
[0000.025] W> RATCHET: MB1 binary ratchet value 4 is larger than ratchet level 2 from HW fuses.
[0000.033] I> MB1 (prd-version: 2.5.0.0-t194-41334769-d9272b5a)
[0000.039] I> Boot-mode: Coldboot
[0000.042] I> Platform: Silicon
[0000.044] I> Chip revision : A02P
[0000.047] I> Bootrom patch version : 15 (correctly patched)
[0000.053] I> ATE fuse revision : 0x200
[0000.056] I> Ram repair fuse : 0x0
[0000.059] I> Ram Code : 0x0
[0000.062] I> rst_source: 0xb, rst_level: 0x1
[0000.067] I> Boot-device: QSPI (instance: 0)
[0000.071] I> Qspi flash params source = brbct
[0000.075] I> Qspi clock source : pllp
[0000.078] I> Qspi-0 initialized successfully
[0000.082] I> Boot chain mechanism: A/B
[0000.085] I> Current Boot-Chain Slot: 1
[0000.089] I> BR-BCT Boot-Chain: 0, status: 1. update flag: 1
[0000.094] I> Qspi flash params source = brbct
[0000.101] W> PROD_CONFIG: device prod data is empty in MB1 BCT.
[0000.106] I> Temperature = 24500
[0000.109] W> Skipping boost for clk: BPMP_CPU_NIC
[0000.114] W> Skipping boost for clk: BPMP_APB
[0000.118] W> Skipping boost for clk: AXI_CBB
[0000.122] W> Skipping boost for clk: AON_CPU_NIC
[0000.126] W> Skipping boost for clk: CAN1
[0000.130] W> Skipping boost for clk: CAN2
[0000.134] I> Boot-device: QSPI (instance: 0)
[0000.138] I> Qspi flash params source = mb1bct
[0000.142] I> Qspi clock source : pllc_out0
[0000.146] I> Qspi-0 reinitialized
[0000.149] I> Qspi flash params source = mb1bct
[0000.162] I> Non-ECC region[0]: Start:0x80000000, End:0x100000000
[0000.169] W> Thermal config not found in BCT
[0000.177] W> MEMIO rail config not found in BCT
[0000.187] I> Qspi flash params source = mb1bct
[0000.200] I> Qspi flash params source = mb1bct
[0000.234] I> Qspi flash params source = mb1bct
[0000.798] I> Qspi flash params source = mb1bct
[0000.815] I> Qspi flash params source = mb1bct
[0000.854] W> Platform config not found in BCT
[0000.881] I> Qspi flash params source = mb1bct
[0000.906] I> MB1 done

����main enter
SPE VERSION #: R01.00.18 Created: Jan 29 2021 @ 14:18:27
HW Function test
Start Scheduler.
in late init
��
  [0000.916] I> Welcome to MB2(TBoot-BPMP) (version: default.t194-mobile-78ae5a2a)
[0000.916] I> DMA Heap @ [0x526fa000 - 0x52ffa000]
[0000.917] I> Default Heap @ [0xd486400 - 0xd48a400]
[0000.918] E> DEVICE_PROD: Invalid value data = 70020000, size = 0.
[0000.923] W> device prod register failed
[0000.927] I> gpio framework initialized
[0000.931] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio' driver
[0000.938] I> tegrabl_gpio_driver_register: register 'nvidia,tegra194-gpio-aon' driver
[0000.946] I> sdcard_params [0, 55, 0, 50] in mb1_bct
[0000.951] I> Boot_device: QSPI_FLASH instance: 0
[0000.955] I> qspi flash-0 params source = boot args
[0000.961] I> QSPI-0l initialized successfully
[0000.971] I> Found 41 partitions in QSPI_FLASH (instance 0)
[0000.972] I> Active Boot chain : 1
[0000.973] E> Cannot find partition bpmp-fw_b
[0000.977] E> Partition bpmp-fw_b not found
[0000.981] I> ���⟟����域����域����域�: execution failed
[0000.987] I> ���域����域����域����域�: execution failed
[0000.992] E> Top caller module: LOADER, error module: PARTITION_MANAGER, reason: 0x0d, aux_info: 0x09
[0001.002] I> AB warm reset
��
[0000.025] W> RATCHET: MB1 binary ratchet value 4 is larger than ratchet level 2 from HW fuses.
[0000.033] I> MB1 (prd-version: 2.5.0.0-t194-41334769-d9272b5a)
[0000.038] I> Boot-mode: Coldboot
[0000.041] I> Platform: Silicon
[0000.044] I> Chip revision : A02P
[0000.047] I> Bootrom patch version : 15 (correctly patched)
[0000.052] I> ATE fuse revision : 0x200
[0000.056] I> Ram repair fuse : 0x0
[0000.059] I> Ram Code : 0x0
[0000.061] I> rst_source: 0xb, rst_level: 0x1
[0000.066] I> Boot-device: QSPI (instance: 0)
[0000.070] I> Qspi flash params source = brbct
[0000.074] I> Qspi clock source : pllp
[0000.078] I> Qspi-0 initialized successfully
[0000.082] I> Boot chain mechanism: A/B
[0000.085] I> Current Boot-Chain Slot: 0
[0000.089] E> Error, current slot 0 fails: sr_bl: 0x4d14ef1, sr_br: 0x0
[0000.095] I> Reset to recovery mode

```

Above is Xavier NX eMMC prod SoM flashed via

```auto
sudo BOARDID=3668 BOARDSKU=0001 FAB=100 ./tools/kernel_flash/l4t_initrd_flash.sh --no-flash --massflash 3 --network usb0 p3509-0000+p3668-0000-qspi nvme0n1p1
sudo ./tools/kernel_flash/l4t_initrd_flash.sh --flash-only --massflash 3 --network usb0 --keep

```

Since it did not seem like the `p3509-0000+p3668-0000-qspi` did anything different in terms of providing fewer things to flash, and of course because it is failing to boot probably because this one is for flashing QSPI onto a development SD card sporting SoM, I’m going back to `p3509-0000+p3668-0001-qspi-emmc` and doing more tests to confirm that step 2 is all I need for NVMe bootability and will hack/adapt the scripts

---

<div class="post-metadata">

**Author:** ![unphased](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@unphased](https://forums.developer.nvidia.com/u/unphased)\
**Post date:** [February 8, 2023, 12:07am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/15 "2023-02-08T00:07:03Z")

</div>

I think my assumption from before was incorrect. interrupting the massflash on the units after step 2 does not restore their ability to boot from NVMe…

I also think that my `p3509-0000+p3668-0000-qspi` attempt earlier may have been affected by udisks2 service somehow having started up again.

Update: masked that service. Did not change behavior.

---

<div class="post-metadata">

**Author:** ![rapidproto](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/rapidproto/32/11458_2.png) [@rapidproto](https://forums.developer.nvidia.com/u/rapidproto)\
**Post date:** [March 6, 2023, 7:16am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/16 "2023-03-06T07:16:03Z")

</div>

I am also trying to massflash Xavier NX NVMe using command line method and it will only flash one device, the other devices do not connect SSH to host and fail to flash

Waiting for target to boot-up…  
Waiting for device to expose ssh …RTNETLINK answers: File exists  
RTNETLINK answers: File exists  
…RTNETLINK answers: File exists  
RTNETLINK answers: File exists  
Waiting for device to expose ssh

The image creation command is (using 99 devices in case of unknown limitations):

sudo ./tools/kernel\_flash/l4t\_initrd\_flash.sh --external-device nvme0n1p1 -c ./tools/kernel\_flash/flash\_l4t\_nvme.xml --no-flash --massflash 99 --showlogs --network usb0 p3509-0000+p3668-0001-qspi-emmc nvme0n1p1

sudo ./tools/kernel\_flash/l4t\_initrd\_flash.sh --flash-only --massflash 99 --showlogs --network usb0 p3509-0000+p3668-0001-qspi-emmc nvme0n1p1

Any help appreciated, not sure if this is command line error, or issue with SSH on host or device.

regards, rapidproto

---

<div class="post-metadata">

**Author:** ![WayneWWW](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/waynewww/32/14043_2.png) [@WayneWWW](https://forums.developer.nvidia.com/u/WayneWWW)\
**Post date:** [March 6, 2023, 9:07am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/17 "2023-03-06T09:07:50Z")

</div>

Hi @rapidproto

Please file a new topic and tag me there. Thanks.

---

<div class="post-metadata">

**Author:** ![rapidproto](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/rapidproto/32/11458_2.png) [@rapidproto](https://forums.developer.nvidia.com/u/rapidproto)\
**Post date:** [March 6, 2023, 11:06am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/18 "2023-03-06T11:06:31Z")

</div>

Thanks Wayne, found solution here and added my findings to this thread…

> [@Xavier NX Jetpack 5.1 initrd massflash doesn't work](https://forums.developer.nvidia.com/t/xavier-nx-jetpack-5-1-initrd-massflash-doesnt-work/242078/9):
>
> I can confirm that code change fixed massflash over here as well. Thanks.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/system/32/68080_2.png) [@system](https://forums.developer.nvidia.com/u/system)\
**Post date:** [March 29, 2023, 4:58am UTC](https://forums.developer.nvidia.com/t/massflash-qspi-to-prod-som/241899/20 "2023-03-29T04:58:39Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
