Project

General

Profile

Building U-Boot for MitySOM-AM57X

Before you begin

There are multiple ways to customize and compile the U-Boot for your project. Please try to build U-Boot as-is with no changes before you try to add your customizations. This will ensure your environment and toolchain are setup correctly.

  1. Docker Build - Build using a Docker image (as described in Docker Build Environment
  2. ARM toolchain - You can use a previously compiled ARM toolchain provided by ARM.
  3. Yocto Environment - If you are using the docker environment and Yocto for your filesystem, you can use its tools to customize and build U-Boot.

In most cases, you will use one of the first two options for initial bring-up and testing. Then, once you have everything working you can integrate your custom code into Yocto.

Critical Link U-Boot Repository

Critical Link recommends using the mitysom-u-boot-2023.04 branch on our git server: https://support.criticallink.com/gitweb/?p=u-boot-ti.git;a=summary

Other MitySOM-AM57x U-Boot branches seen on the repository should not be considered stable, and are used for internal feature development.

U-Boot Build - Docker

See Docker Build Environment for details on how to setup and install the Docker build environment. Once that is installed, you can build U-Boot using the following commands:

git clone --branch mitysom-u-boot-2023.04 https://support.criticallink.com/git/u-boot-ti.git
cd u-boot-ti
docker run --rm --volume "$PWD:/work" --workdir=/work mitysom_ubuntu:22.04 ./57x-build.sh

If the build is successful, you will see MLO and u-boot.img files in the current directory. You can copy those to your boot media to test your new build. When U-Boot boots, it will display the build date and time. Please check this to make sure your new U-Boot files are being used.

For example, note the two dates, one for the MLO and one for the u-boot.img:

U-Boot SPL 2023.04-00489-g5da3ed2aefa (Jul 30 2025 - 11:46:33 -0400)
DRA762-GP ES1.0 ABZ package
no pinctrl state for default mode
Firmware loading failed for ipu2
Trying to boot from MMC1
Loading Environment from FAT... *** Error - No Valid Environment Area found
*** Warning - bad env area, using default environment

Loading Environment from MMC... MMC Device 1 not found
*** Warning - No MMC card found, using default environment

U-Boot 2023.04-00489-g5da3ed2aefa (Jul 30 2025 - 11:46:33 -0400)

An example pinmux for Critical Link's development board can be found in board/cl/mitysom-57x/mux_data.h.

Please contact Critical Link at if you need help with customizing your defconfig and pinmux for your application.

Deploy Scripts/Helpful Scripts

Several additional scripts are provided to do helpful things.

57x-copy.sh - Copies the files to a locally mounted SD card (assumed to be at /media/$USER).
57x-push.sh - Push the files to a SD card connected to a board over the network. You must supply a SSH connection string as the first argument (ex: root@<board ip address> ) or configure a ssh host target.

U-Boot Build - Yocto

For this option, you should have an environment setup as described in Docker build environment and Building the filesystem for the MitySOM-AM57x.

With this option, the general Yocto setup configures your build environment. You can compile U-Boot by running bitbake commands from your build directory.

Customize your U-Boot

You can customize U-Boot by pointing the U-Boot recipe to your new branch location.

In your Yocto meta layer, create a u-boot bbappend file. File name is important to match existing u-boot recipe name, as of Feb 2021 the name is below
[meta-mitysom.git] / recipes-bsp / u-boot / attachment:u-boot-cl-ti_2023.04.bb

mkdir recipes-bsp/u-boot/
vim u-boot-ti-staging_2023.03.bbappend

UBOOT_GIT_URI_mitysom-am57x = "git://support.criticallink.com/git/u-boot-ti.git" 
UBOOT_GIT_PROTOCOL_mitysom-am57x = "http" 

BRANCH = "mitysom-u-boot-2023.04" 
SRCREV = "${AUTOREV}" 
  • Point UBOOT_GIT_URI* to your repository
  • Update BRANCH to match your branch
  • SRCREV can be set to a specific git hash if you want to lock to a specific commit instead of letting it grab the latest in the branch.

Building U-Boot

Then, to build U-Boot (note that this is within the previously configured Docker environment):

oe-layersetup$ ./docker-poky.sh
pokyuser@cc6ebed1f954:/work$ ./57x-setup.sh --next
pokyuser@cc6ebed1f954:/work$ export MACHINE=mitysom-am57x
pokyuser@cc6ebed1f954:/work$ pushd build
pokyuser@cc6ebed1f954:/work$ source conf/setenv
user@8ec23474095b:~$ MACHINE=mitysom-am57x bitbake virtual/bootloader

If the build is successful, you will find your MLO and u-boot.img file in build/deploy-ti/images/mitysom-am57x/.

Verifying Your U-Boot Output and Build

If successful, you should see the following in the build output:

MKIMAGE u-boot.img
MKIMAGE MLO
make[1]: Leaving directory '/export/home/jsava/u-boot-ti/build-mitysom57x'

When U-Boot boots, it will display the build date and time. Please check this to make sure your new U-Boot files are being used.

U-Boot SPL 2023.04-g5766bfa7bf (Aug 07 2025 - 19:34:19 +0000)
DRA762-GP ES1.0 ABZ package
no pinctrl state for default mode
Firmware loading failed for ipu2
Trying to boot from MMC1
Loading Environment from FAT... OK

U-Boot 2023.04-g5766bfa7bf (Aug 07 2025 - 19:34:19 +0000)

CPU  : DRA762-GP ES1.0 ABZ package
Model: Critical Link MitySOM-AM57x
Board: MitySOM-57x FPGA
DRAM:  2 GiB
Core:  74 devices, 28 uclasses, devicetree: separate
MMC:   OMAP SD/MMC: 0
Loading Environment from FAT... OK
MitySOM-57x - Model No: 5728-PJ-4AA-RC Serial No: 20015828 Part Number: 80-001294RC-1B
Warning: fastboot.board_rev: unknown board revision
invalid mmc device
board_set_pru_ethaddr
Net:   eth4: ethernet@48484000

Go to top
Add picture from clipboard (Maximum size: 1 GB)