SDAA437 July   2026 TDA4VE-Q1

 

  1.   1
  2.   Abstract
  3.   Trademarks
  4. 1 Introduction
    1. 1.1 Motivation
    2. 1.2 Scope
    3. 1.3 Target Boot Architecture
  5. 2 Background
    1. 2.1 J721S2 Boot Flow
    2. 2.2 OSPI NOR Flash Overview
    3. 2.3 UBI and UBIFS Overview
  6. 3 OSPI Flash Layout
    1. 3.1 Partition Layout
    2. 3.2 Bootloader Partitions
    3. 3.3 Root Filesystem Partition
  7. 4 Flashing Boot Components
    1. 4.1 Boot Components Overview
    2. 4.2 Identifying OSPI MTD Partitions
    3. 4.3 Flashing Boot Components into OSPI NOR Flash
    4. 4.4 Verifying Boot Components
  8. 5 Creating a UBIFS Root Filesystem
    1. 5.1 Preparing the RootFS Partition
    2. 5.2 Creating a UBI Device
    3. 5.3 Creating a UBIFS Volume
    4. 5.4 Verifying UBIFS Operation
  9. 6 Storing Linux Boot Artifacts in UBIFS
    1. 6.1 Mounting the UBIFS Root Filesystem Volume
    2. 6.2 Creating the Root Filesystem Structure with BusyBox
    3. 6.3 Verifying BusyBox Execution
    4. 6.4 Creating BusyBox Command Links
    5. 6.5 Creating the init Script
    6. 6.6 Testing the Root Filesystem Using chroot
    7. 6.7 Copying the Linux Kernel Image and DTB
  10. 7 Configuring Linux Boot from UBIFS
    1. 7.1 Configuring Boot Arguments
    2. 7.2 Loading the Kernel and DTB from UBIFS
    3. 7.3 Testing Linux Boot
    4. 7.4 Creating a Reusable Boot Command
  11. 8 Booting Linux Entirely from OSPI NOR Flash
    1. 8.1 Automating the Boot Sequence in U-Boot
    2. 8.2 End-to-End Boot Flow
  12. 9 Summary
  13. 10References

Flashing Boot Components into OSPI NOR Flash

After identifying the OSPI MTD partitions, the boot components can be flashed into OSPI NOR flash.

During development, the boot component images were obtained from the SD card boot partition used to boot the J721S2 EVM. The locations of the boot component images will be found at /run/media/BOOT-mmcblk1p1 as follows.

root@j721s2-evm:~# ls -l /run/media/BOOT-mmcblk1p1/
total 4906
-rwxrwx--- 1 root disk  465805 Jun 13  2026 tiboot3-j721s2-gp-evm-j721s2-evm-k3r5-2025.01+git97201+743712b-r0_tisdk_6_edgeai_5.bin
-rwxrwx--- 1 root disk  465805 Jun 13  2026 tiboot3-j721s2-gp-evm.bin
-rwxrwx--- 1 root disk  468394 Jun 13  2026 tiboot3-j721s2-hs-evm.bin
-rwxrwx--- 1 root disk  468394 Jun 13  2026 tiboot3-j721s2-hs-fs-evm.bin
-rwxrwx--- 1 root disk  465805 Jun 13  2026 tiboot3.bin
-rwxrwx--- 1 root disk 1326915 Jun 13  2026 tispl.bin
-rwxrwx--- 1 root disk 1359931 Jun 13  2026 u-boot.img
-rwxrwx--- 1 root disk     941 Jun 13  2026 uEnv.txt
-rwxrwx--- 1 root disk      14 Jun 13  2026 version

Table 4-1 shows the mapping between the boot component images and their target OSPI partitions.

Table 4-1 Boot Component Flashing Target
Image Target MTD Device OSPI Partition
tiboot3.bin/dev/mtd0ospi.tiboot3
tispl.bin/dev/mtd1ospi.tispl
u-boot.img/dev/mtd2ospi.u-boot

The boot components are flashed using the Linux flashcp utility.

root@j721s2-evm:~# flashcp /run/media/BOOT-mmcblk1p1/tiboot3.bin /dev/mtd0
root@j721s2-evm:~# flashcp /run/media/BOOT-mmcblk1p1/tispl.bin   /dev/mtd1
root@j721s2-evm:~# flashcp /run/media/BOOT-mmcblk1p1/u-boot.img  /dev/mtd2

After flashing completes, the OSPI NOR flash contains all boot software required to reach the U-Boot prompt. The next section verifies that the flashed images can be successfully loaded when the board is configured for OSPI boot mode.