Change default option of booting to USB

Hello,

I have to flash linux kernel version 4.9 (L4T 32.4.4) Ubuntu 18.04 , in my Jetson NX SOM custom carrier board.

Due to some error , i am not getting this booting sequence option

Hence please help me with the steps so that , MY CUSTOM CARRIER BOARD boots default by USB not by SD card.

Then what did you see on your side?

And did you flash your board with sdkmanager?

Hello,

  1. sir , please help me with steps/changes. How can i change the default booting device to USB , instead of SD card.

  2. As you suggested me in previous thread i am going to use sdkmanager.

  3. As you asked me , what i am getting is repeated logsā€¦
    repeated_logs_nx_som_in_customcarrierboard.txt (17.8 KB)

Then you should fix your custom board hardware problem first instead of asking something like ā€œboot device to usbā€.

Sure sir, our hardware team is working on it.
But just to enhance my knowledge , Can you please let me know that

" How can i change the default booting device to USB , instead of SD card "

To be honestly, you should follow things one by one. I donā€™t think you would be able to understand how to do this under the situation that you donā€™t even try sdkmanager before.

https://docs.nvidia.com/jetson/l4t/index.html#page/Tegra%20Linux%20Driver%20Package%20Development%20Guide/flashing.html#wwpID0E01O0HA

I have to agree that working on boot wonā€™t succeed unless other parts work first, but you might find this thread of use for finding out what you can observe in the environment of CBoot:
https://forums.developer.nvidia.com/t/cboot-console-set-var-command/174742

Thanks for your reply.

Sir ,as you suggested that , it may be hardware issue. I agree with that , my hardware team is looking into it, whereas as i am exploring ways in software side.

Trying to flash my NX DEV KIT by , USB

==> While trying to flash with usb , i used these steps (in recovery mode)

  1. Connect my usb pendrive to host pc
  2. sudo lsblk -p -d | grep sd
  3. sudo parted /dev/sda mklabel gpt
  4. sudo parted /dev/sda mkpart APP 0GB 16GB
  5. sudo mkfs.ext4 /dev/sda1
  6. sudo mount /dev/sda1 /mnt
  7. $ cd Linux_for_Tegra/
    $ sudo BOOTDEV=sda1 ./flash.sh --no-flash jetson-xavier-nx-devkit-emmc sda1
    $ sudo mkdir tmp_system
    INORDER TO RUN NEXT COMMAND
    $ sudo mount bootloader/system.img.raw ./tmp_system

system.img.raw , is not present in bootloader/ directory.
What shall i do ?

==> Secondly i also tried to prepare USB image , simply as i do it by SD card by balenaetcher software.

while booting the nx dev kit board by usb , i get

but i m facing these logs ,
[0013.155] I> Disable plugin-manager status in FDT
[0013.157] I> Plugin-manager override finished successfully
[0013.162] I> tegrabl_load_kernel_and_dtb: Done
[0013.188] I> Kernel EP: 0x80080000, DTB: 0x90000000
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 4.9.253-tegra (buildbrain@mobile-u64-5497-d3000) (gcc version 7.3.1 20180425 [linaro-7.3-2018.05 revision d29120a424ecfbc167ef90065c0eeb7f91977701] (Linaro GCC 7.3-2018.05) ) #1 SMP PREEMPT Mon Jul 26 12:19:28 PDT 2021
[ 0.000000] Boot CPU: AArch64 Processor [4e0f0040]
[ 0.000000] OF: fdt:memory scan node memory, reg size 48,
[ 0.000000] OF: fdt: - 80000000 , 2c000000
[ 0.000000] OF: fdt: - ac200000 , 44800000
[ 0.000000] OF: fdt: - 100000000 , 180000000
[ 0.000000] earlycon: tegra_comb_uart0 at MMIO32 0x000000000c168000 (options ā€˜ā€™)
[ 0.000000] bootconsole [tegra_comb_uart0] enabled
[ 0.000000] Found tegra_fbmem: 00800000@a06a9000
[ 0.000000] Found lut_mem: 00002008@a06a4000
ā–’ā–’WARNING: pll_d2 has no dyn ramp
ā–’ā–’[ 1.961764] imx219 9-0010: imx219_board_setup: error during i2c read probe (-121)
[ 1.962143] imx219 9-0010: board setup failed
[ 1.986142] imx219 10-0010: imx219_board_setup: error during i2c read probe (-121)
[ 1.986463] imx219 10-0010: board setup failed
ā–’ā–’WARNING: at platform/drivers/pg/pg-gpu-t194.c:185
WARNING: at platform/drivers/pg/pg-gpu-t194.c:185

and display connected to hdmi shows, bash shell

Why my NX dev kit is not booting my USB .i tried both the mentioned aboveā€¦

Please helpā€¦

jetson-xavier-nx-devkit-emmc is for emmc only. Read the quick start guide to pick up the correct board config for yourself.

Please do have some ability to read document and find the correct info first.

Also, always share the full log unless you are pretty sure where is the error cause. But it looks like you are not.

Hello ,

Actually especifically nothing for written for USB ,

Please have a look into the complete logs.

logs_usb_flash_nx_dev_kit.txt (53.6 KB)

Yes, that is your problem. You cannot tell things even after you read the log.

Below is the usb boot failure log from you txt file.

[0004.068] I> ########## USB (0) boot ##########
[0004.073] W> No valid slot number is found in scratch register
[0004.073] W> Return default slot: _a
[0004.087] I> Validate XUSB-FW ā€¦
[0004.087] I> T19x: Authenticate XUSB-FW (bin_type: 11), max size 0x30000
[0004.089] I> Encryption fuse is not ON
[0004.089] I> USB Firmware Version: 60.09 release
[0004.146] I> regulator of usb2-0 already enabled
[0004.151] I> regulator of usb2-1 already enabled
[0004.155] I> regulator of usb2-2 already enabled
[0005.221] I> USB 2.0 port 2 new high-speed USB device detected
[0005.222] W> WARNING: event and command not matching, cmd_trb_ptr = 0xa4ad1000, cmd_ring.dma = 0xa4ad10c0
[0005.323] I> Start to enumerate device
[0005.325] W> WARNING: event and command not matching, cmd_trb_ptr = 0xa4ad1000, cmd_ring.dma = 0xa4ad10c0
[0005.334] I>
[0005.335] I> Enumerated USB Device 0bda:5489
[0005.335] I>
[0005.337] I> Hub:
[0005.337] I> Downstream ports : 4
[0005.337] I> Power switching : Ganged
[0005.338] I> Compound device : No
[0005.338] I> Over-current protection : Global
[0005.338] I> Hub avg delay : 4 ns
[0005.340] I> Set interface = 1 (alt setting)
[0005.346] I> Enable hub ports
[0005.558] I> Device detected on port 2
[0005.762] I> Device detected on port 3
[0006.370] I> Reset port 2
[0006.424] I> Port 2 device is low speed, skip enumeration
[0006.426] I> Reset port 3
[0006.482] W> WARNING: event and command not matching, cmd_trb_ptr = 0xa4ad1000, cmd_ring.dma = 0xa4ad10c0
[0006.583] I> Start to enumerate device
[0006.584] W> WARNING: event and command not matching, cmd_trb_ptr = 0xa4ad1000, cmd_ring.dma = 0xa4ad10c0
[0006.647] W> WARNING: event and command not matching, cmd_trb_ptr = 0xa4ad1100, cmd_ring.dma = 0xa4ad10c0
[0006.649] I>
[0006.649] I> Enumerated USB Device 0951:1666
[0006.649] I>
[0006.650] I> Max LUN = 0
[0006.654] I> Vendor Identification : Kingston
[0006.654] I> Product Identification : DataTraveler 3.0
[0006.654] I> Product Revision Level : PMAP
[0006.660] I> READ CAPACITY - last LBA = 60530688, 29556MB
[0006.660] I> -0 params source =
[0006.708] I> Found 11 partitions in USB_MS (instance 0)
[0006.709] I> Look for boot partition
[0006.709] I> Fallback: assuming 0th partition is boot partition
[0006.710] I> Detect filesystem
[0006.725] I> Loading kernel-bootctrl from partition
[0006.726] I> Loading partition kernel-bootctrl at 0xa4b70000 from device(0x5)
[0006.743] W> tegrabl_get_kernel_bootctrl: magic number(0x00000000) is invalid
[0006.743] W> tegrabl_get_kernel_bootctrl: use default dummy boot control data
[0006.744] I> Loading extlinux.conf ā€¦
[0006.744] I> Loading extlinux.conf binary from rootfs ā€¦
[0006.745] I> rootfs path: /usb/boot/extlinux/extlinux.conf
[0006.768] I> Loading extlinux.conf sig file from rootfs ā€¦
[0006.768] I> rootfs path: /usb/boot/extlinux/extlinux.conf.sig
[0006.781] I> Validate extlinux.conf ā€¦
[0006.781] I> T19x: Authenticate extlinux.conf (bin_type: 54), max size 0x2000
[0006.782] I> Encryption fuse is not ON
[0006.782] I> L4T boot options
[0006.783] I> [1]: ā€œprimary kernelā€
[0006.783] I> Enter choice:
[0009.511] I> Selected option: 1
[0009.511] I> Loading kernel ā€¦
[0009.511] I> Loading kernel binary from rootfs ā€¦
[0009.511] I> rootfs path: /usb/boot/Image
[0010.559] W> handle_transfer_event: WARNING: Command was not successfully completed (0x04)
[0013.567] W> xusbh_wait_irq: Timed out! status = 0x00
[0013.568] E> Bad CSW SIG (0)!
[0013.669] E> USBMSD: Invalid value CSW SIG 0.
[0013.669] E> Error reading 128 blocks @ 26855040
[0013.670] E> USBMSD: Could not read sector 26855040 count 128.
[0013.670] E> USBMSD: Could not read sector 26822656 count 67360.
[0013.671] E> Blockdev read block: exit error = e7c1102
[0013.671] E> Blockdev read: exit error = e7c1102
[0013.674] I> ext4_read_extent:215: blockdev read failed
[0013.679] E> file /usb/boot/Image read failed!!
[0013.683] W> Failed to load kernel binary from rootfs (err=202113305)
[0013.689] I> Continue to load from partition ā€¦
[0013.694] W> No valid slot number is found in scratch register
[0013.700] W> Return default slot: _a
[0013.703] I> A/B: bin_type (37) slot 0
[0013.707] I> Loading kernel from partition
[0013.711] I> Loading partition kernel at 0xa4b70000 from device(0x5)
[0016.725] W> xusbh_wait_irq: Timed out! status = 0x00
[0019.732] W> xusbh_wait_irq: Timed out! status = 0x00

Sir ,

What should i do now , our plan to use SD card flashing , USB flashing , sdkmanager all are not working for NX som in custom carrier board .

As you are repeatedly telling us that it can be ā€œhardware issueā€ ā€¦
But how to identify that hardware issue , like in which direction they should look.
Because they have check the power, impedance and again reviewed the schematic , but everything seems fineā€¦

If you want , i can share some of the portion of schmeatic to you as well (our pin configuration are same as that of dev kit).

Please helpā€¦

What is exact thing you are trying here? Are you trying to boot from usb on your custom board? Or on the devkit?

If you need hardware help on your custom board, my colleague @Trumany can help. Please file a topic, paste your schematic, use the correct module to test instead of sdcard module.

Thank for providing reference.

Sir i am trying all other different methods because ,
=> my custom carrier board using NX som is not booting from SD card (we do not have the emmc facility).

==> Whereas my custom carrier board using Nano SoM is booting perfectly fine from SD card.

Just some basic concept.

If you want to try usb boot on the devkit, I can guide you. But I donā€™t suggest you to immediately try this on your custom board because this just puts potential risk.

Learn to do things on devkit first and then move to custom boardā€¦ if you even fail on devkit, no need to mention on your custom boardā€¦

When the system is flashed this file is generated during the flash.

Yes sir, i want to implement this ā€œusb boot, by pendriveā€ in devkit first ,
if everything goes fine , then only i will implement the same in custom carrier board.

"HERE I have made by usb bootable by using balenaetcher and connected the pendrive in Nano dev kit "
but i am getting these logs

copying carveout for /host1x@50000000/dc@54240000ā€¦
Starting kernel ā€¦

[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 4.9.253-tegra (buildbrain@mobile-u64-5496-d5000) (gcc version 7.3.1 20180425 [linaro-7.3-2018.05 revision d29120a424ecfbc167ef90065c0eeb7f91977701] (Linaro GCC 7.3-2018.05) ) #1 SMP PREEMPT Mon Jul 26 12:13:06 PDT 2021
[ 0.000000] Boot CPU: AArch64 Processor [411fd071]
[ 0.000000] OF: fdt:memory scan node memory@80000000, reg size 32,
[ 0.000000] OF: fdt: - 80000000 , 7ee00000
[ 0.000000] OF: fdt: - 100000000 , 7f200000
[ 0.000000] Found tegra_fbmem: 00800000@92ca9000
[ 0.000000] earlycon: uart8250 at MMIO32 0x0000000070006000 (options ā€˜ā€™)
[ 0.000000] bootconsole [uart8250] enabled
[ 1.161325] tegradc tegradc.1: dpd enable lookup fail:-19
[ 1.323803] imx219 7-0010: imx219_board_setup: error during i2c read probe (-121)
[ 1.323870] imx219 7-0010: board setup failed
[ 1.347687] imx219 8-0010: imx219_board_setup: error during i2c read probe (-121)
[ 1.347743] imx219 8-0010: board setup failed

and getting bash-4.4# shell in display

complete logs are attached below
usb_booting_in_nano_dev_kit.txt (22.5 KB)

I donā€™t want to repeat the same things again.

Use sdkmanager or flash.sh to flash your devkit first. And follow the document I posted earliler. If this is new to you, then you need to learn to use this tool.

Forget about balenaetcher. We donā€™t use sdcard image for any kind of customization. Even the usb boot.

Also, the document is based on the flash.sh tool but not sdcard image.

I donā€™t know what kind of problem to you that you just keep using sdcard image and cannot listen to suggestion.

One mistake people often make is to think all boot content of an SD card model is on the SD card. It is not. Flashing will program SD card modelā€™s QSPI memory, which has that boot content. Changing release on the SD card often requires also changing release in the QSPI content. Canā€™t do that without flashing.

1 Like

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