NXP real-time-edge linux

NXP, producer of the i.MX8MP chip on the Debix A platform provides a linux variant with AVB/TSN capabilities. Please refer to the separate page for further details.

Compile (custom) kernel

We need the following steps for cross-compilation: Clone (only specific branch) of linux repository:

git clone --depth=1 https://github.com/debix-tech/linux -b Model_AB-L6.1.22 linux-debix
cd linux-debix

Set system parameters:

CORES=$(getconf _NPROCESSORS_ONLN)
REV=elak-spl
export ARCH=arm64
export CROSS_COMPILE=aarch64-linux-gnu-

Set default configuration:

make clean
make imx_v8_defconfig

Using make menuconfig, set CONFIG_HZ_1000=y and CONFIG_SND_SOC_PCM5102A=m. Then make oldconfig.

Build kernel image:

make -j${CORES} KBUILD_DEBARCH=arm64 LOCALVERSION=-rt-${REV} Image

or, build binary debian packages:

make -j${CORES} KBUILD_DEBARCH=arm64 LOCALVERSION=-rt-${REV} bindeb-pkg

Resulting debian packages are linux-image-*-rt-elak-spl_arm64.deb, linux-headers-*-rt-elak-spl_arm64.deb, and linux-libc-dev_arm64.deb.

Install kernel binary

The Image kernel binary can be installed over the existing kernel /boot/Image. There is no apt-installed linux-image-* debian package in the debix Ubuntu 22.04.3 LTS distribution.

Set u-boot environment

The u-boot menu can be accessed from the tty console (GND=pin 5/7=GND, RX=pin 9, TX=pin 11). A key press while booting accesses the boot menu.

setenv image Image 
setenv fdtfile imx8mp-evk.dtb
saveenv

Build u-boot

Clone (only specific branch) of uboot repository:

git clone -b lf_v2022.04 --depth=1  https://github.com/debix-tech/uboot.git uboot-debix
cd uboot-debix

Set system parameters, as above:

CORES=$(getconf _NPROCESSORS_ONLN)
export ARCH=arm64
export CROSS_COMPILE=aarch64-linux-gnu-

Configure with make imx8mp_evk_defconfig and build with make -j${CORES}.

NOTE: According to the uboot IMX8MP docs we probably also have to include the ARM Trusted firmware (ATF) binaries.