Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

https://git.seco.com/seco-ne/kernel/linux-imx-kuk

Linux 5.10.9 based on Android 11.0.0_2.0.0

ssh://git@git.seco.com:seco-ne/kernel/linux-imx-kuk.git
https://git.seco.com/seco-ne/kernel/linux-imx-kuk.git

kuk_lf-5.10.y_android_compilable

Previous Versions

Branch/Tag

Comment

Kernel Binaries

Date

Changelog

Download

28.02.2022

image.zip linux-5.10.9-modules.tar.gz

How to Build Linux Kernel for Trizeps VIII & Trizeps VIII Mini

This is only a quick-reference on how to build a Linux Kernel including Seco specific changes.
For details please view the Linux and NXP i.MX8M documentation.

Get the source code of linux-imx from git repository:

$ git clone https://git.seco.com/seco-ne/kernel/linux-imx-kuk.git -b kuk_lf-5.10.y_android_compilable

Setup Cross-Build environment (View Software-Development-Kit on how to install.):

$ . /opt/fsl-imx-wayland/5.10-hardknott/environment-setup-cortexa53-crypto-poky-linux
$ export ARCH=arm64

Build Linux-Kernel from source code:

~/linux-imx$ make kuk_defconfig
~/linux-imx$ make

This will generate linux kernel ('Image') and device-tree binary ('*.dtb') files.

~/linux-imx/arch/arm64/boot/Image
~/linux-imx/arch/arm64/boot/dts/keithkoep/*.dtb

After you generated the kernel, you might want to build the kernel-modules:

~/linux-imx$ make modules_install INSTALL_MOD_PATH=~/linux-imx-modules

Note: When the kernel boots it loads kernel-modules from the root-filesystem at '/lib/modules/<kernel-build-number>' (i.e. /lib/modules/5.10.9).
Note: if kernel stops compiling missing bio.h : –> apt install libssl-dev

Update Kernel

Updating the kernel involves to copy 'Image' and the kernel-module directory to the device.
If the kernel-build-version did not change, copy of the kernel-module directory can be omitted.

Update using USB and bootloader

Enter the bootloader command console and run:

u-boot=> ums 0 mmc 0

This will configure the USB-OTG port to emulate a USB-Mass-Storage device.
Example:

$ lsblk
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0   240G  0 disk 
├─sda1   8:1    0   232G  0 part /
└─sda2   8:2    0     8G  0 part 
sde      8:64   1   3,8G  0 disk 
└─sde1   8:65   1   3,8G  0 part /media/imx6/9016-4EF8
sdf      8:80   1   7,1G  0 disk 
├─sdf1   8:81   1   500M  0 part /media/imx6/00BA-BF8A
└─sdf2   8:82   1   6,6G  0 part /media/imx6/fd195515-0a44-4a7e-9387-bec6087f37ac
sr0     11:0    1  1024M  0 rom  

After calling 'ums 0 mmc 0' a new device 'sdf' appears in the list of mounted devices.

Copy the kernel-'Image' and device-tree binary files to the first partition.

$ cp ~/linux-imx/arch/arm64/boot/Image /media/imx6/00BA-BF8A/Image
$ cp ~/linux-imx/arch/arm64/boot/dts/keithkoep/*.dtb /media/imx6/00BA-BF8A/

Copy the kernel-modules-directory to the second partition that contains the root-filesystem.

cp -r ~/linux-imx-modules/* /media/imx6/fd195515-0a44-4a7e-9387-bec6087f37ac

Hints on using the Kernel

Device Tree

The Linux-kernel will use a Device-Tree-Binary file (.dtb) to determine how the Trizeps module is used in a system (i.e. which drivers to load). The device-tree files can be found at:

~/linux_imx/arch/arm64/boot/dts/keithkoep

When building the Linux-kernel .dts source-files are converted to .dtb binary files.

DeviceTree (dtb)

Module

Description

kuk-trizeps8mini-ipant7.zip

Trizeps VIII Mini

Trizeps VIII Mini in i-PAN T7 V1 panel

kuk-trizeps8mini-ipant7_v2.zip

Trizeps VIII Mini

Trizeps VIII Mini in i-PAN T7 V2 panel

kuk-trizeps8mini-pconxs-edt7cap.zip

Trizeps VIII Mini

Trizeps VIII Mini in pConXS V1 with capacitive touch EDT 7inch display

kuk-trizeps8mini-pconxs_v2-edt7cap.zip

Trizeps VIII Mini

Trizeps VIII Mini in pConXS V2 with capacitive touch EDT 7inch display

kuk-trizeps8mini-pconxs_v3-atm0700.zip

Trizeps VIII Mini

Trizeps VIII Mini in pConXS V3 with ATM0700 7inch display

kuk-trizeps8mini-pconxs_v3-am19201080d1tzqw.zip

Trizeps VIII Mini

Trizeps VIII Mini in pConXS V3 with AM19201080 10inch display

kuk-sbcsom-atm0700l61ct.zip

SBCSOM

SBCSOM with ATM0700 7inch display

kuk-sbcsom-hdmi.zip

SBCSOM

SBCSOM with HDMI display

When you open the u-boot command prompt and output the environment, you can determine which device-tree is used:

u-boot=> env print -a
...
fdt_file=kuk-trizeps8.dtb
...

To change this you can call:

u-boot=> env set fdt_file kuk-trizeps8-pconxs-edt7.dtb
u-boot=> env save

'env save' will store this setting for subsequent boots.

Root-Filesystem

To have a full running Linux-system you will need:

  • Bootloader ( U-Boot, Trizeps VIII Mini ), which loads the Device-Tree and Linux-Kernel.

  • Linux Kernel

  • Root-Filesystem, which contains applications, configuration files etc.

There are different approaches on how to create a root-filesystem.
Basicly its a linux-distribution like Debian, where the system is put together by packages or like Yocto, where recipes define what needs to be built and put inside the file-system:

  • No labels