Create custom bootable system.img
  • 19 Sep 2022
  • 1 Minute to read
  • Dark
    Light
  • PDF

Create custom bootable system.img

  • Dark
    Light
  • PDF

Demo image (system.img)

There are two step to do:

  1. Prepare files
  2. create system.img

1. Prepare files

  • kernel Image
  • kernel modules
  • kernel dts
  • u-boot.bin (Nano with TEK3-NVJETSON only)
  • pinmux (Xavier NX series only)
  • change boot config for custom device-tree(overlay)



kernel Image

Copy from:

<nvidia_folder>/Linux_for_Tegra/sources/kernel/kernel-4.9/arch/arm64/boot/Image

to here

<nvidia_folder>/Linux_for_Tegra/kernel/

kernel modules

Copy from

<nvidia_folder>/Linux_for_Tegra/sources/kernel/modules/lib/

to here

<nvidia_folder>/Linux_for_Tegra/rootfs/

device-tree

Copy from

<nvidia_folder>/Linux_for_Tegra/sources/kernel/kernel-4.9/arch/arm64/boot/dts/<target>.dtb 

to here

<nvidia_folder>/Linux_for_Tegra/rootfs/boot/<target>.dtb

u-boot.bin (Nano with TEK3-NVJETSON only)

Copy from

<nvidia_folder>/Linux_for_Tegra/sources/u-boot/u-boot.bin

to here

<nvidia_folder>/Linux_for_Tegra/bootloader/t210ref/p3450-0000/u-boot.bin

pinmux(For Xavier NX only)

Copy

tegra19x-mb1-pinmux-p3668-a01.cfg

to here

<nvidia_folder>/Linux_for_Tegra/bootloader/t186ref/BCT/tegra19x-mb1-pinmux-p3668-a01.cfg

boot config for custom device-tree

<nvidia_folder>/Linux_for_Tegra/rootfs/boot/extlinux/extlinux.conf
LABEL primary
      MENU LABEL primary kernel
      LINUX /boot/Image
      INITRD /boot/initrd
+     FDT /boot/<target>.dtb
-     APPEND ${cbootargs} quiet
+     APPEND ${cbootargs} 
Only Nano support device-tree overlay(FDTOVERLAYS)
LABEL primary
      MENU LABEL primary kernel
      LINUX /boot/Image
      INITRD /boot/initrd
      FDT /boot/<target>.dtb
+     FDTOVERLAYS /boot/<target_overlay>.dtbo
      APPEND ${cbootargs} 

2. create system.img

$ sudo ./flash.sh --no-flash <board> mmcblk0p1

or flashing into device using

$ sudo ./flash.sh <board> mmcblk0p1

Was this article helpful?

What's Next