blob: ffc4c7d222a8a1af86c24201bc51edfbe0ccde8d [file] [log] [blame]
Marcel Ziswiler4d1fea92023-08-29 00:01:53 +02001.. SPDX-License-Identifier: GPL-2.0-or-later
2.. sectionauthor:: Marcel Ziswiler <marcel.ziswiler@toradex.com>
Igor Opaniuk6f04caf2020-02-12 17:14:30 +02003
Marcel Ziswiler4d1fea92023-08-29 00:01:53 +02004Apalis iMX8 Module
5==================
6
7- SoM: https://www.toradex.com/computer-on-modules/apalis-arm-family/nxp-imx-8
8- Carrier board: https://www.toradex.com/products/carrier-board/apalis-evaluation-board
Igor Opaniuk6f04caf2020-02-12 17:14:30 +02009
10Quick Start
11-----------
12
13- Build the ARM trusted firmware binary
14- Get scfw_tcm.bin and ahab-container.img
15- Build U-Boot
16- Load U-Boot binary using uuu
17- Flash U-Boot binary into the eMMC
18- Boot
19
20Get and Build the ARM Trusted Firmware
21--------------------------------------
22
23.. code-block:: bash
24
Fabio Estevamf0f46122023-01-12 21:52:23 -030025 $ git clone -b imx_4.14.78_1.0.0_ga https://github.com/nxp-imx/imx-atf
Igor Opaniuk6f04caf2020-02-12 17:14:30 +020026 $ cd imx-atf/
27 $ make PLAT=imx8qm bl31
28
29Get scfw_tcm.bin and ahab-container.img
30---------------------------------------
31
32.. code-block:: bash
33
34 $ wget https://github.com/toradex/meta-fsl-bsp-release/blob/toradex-sumo-4.14.78-1.0.0_ga-bringup/imx/meta-bsp/recipes-
35 bsp/imx-sc-firmware/files/mx8qm-apalis-scfw-tcm.bin?raw=true
36 $ mv mx8qm-apalis-scfw-tcm.bin\?raw\=true mx8qm-apalis-scfw-tcm.bin
37 $ wget https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/firmware-imx-8.0.bin
38 $ chmod +x firmware-imx-8.0.bin
39 $ ./firmware-imx-8.0.bin
40
41Copy the following binaries to the U-Boot folder:
42
43.. code-block:: bash
44
45 $ cp imx-atf/build/imx8qm/release/bl31.bin .
46 $ cp u-boot/u-boot.bin .
47
48Copy the following firmware to the U-Boot folder:
49
50.. code-block:: bash
51
52 $ cp firmware-imx-8.0/firmware/seco/ahab-container.img .
53
54Build U-Boot
55------------
Marcel Ziswiler4d1fea92023-08-29 00:01:53 +020056
Igor Opaniuk6f04caf2020-02-12 17:14:30 +020057.. code-block:: bash
58
Philippe Schenkerbf464742020-08-28 21:08:06 +030059 $ make apalis-imx8_defconfig
Igor Opaniuk6f04caf2020-02-12 17:14:30 +020060 $ make u-boot-dtb.imx
61
62Load the U-Boot Binary Using UUU
63--------------------------------
64
65Get the latest version of the universal update utility (uuu) aka ``mfgtools 3.0``:
66
67https://community.nxp.com/external-link.jspa?url=https%3A%2F%2Fgithub.com%2FNXPmicro%2Fmfgtools%2Freleases
68
Marcel Ziswiler4d1fea92023-08-29 00:01:53 +020069Put the module into USB recovery aka serial downloader mode, connect the USB
70device to your host and execute ``uuu``:
Igor Opaniuk6f04caf2020-02-12 17:14:30 +020071
72.. code-block:: bash
73
74 sudo ./uuu u-boot/u-boot-dtb.imx
75
76Flash the U-Boot Binary into the eMMC
77-------------------------------------
78
79Burn the ``u-boot-dtb.imx`` binary to the primary eMMC hardware boot area
80partition and boot:
81
82.. code-block:: bash
83
84 load mmc 1:1 $loadaddr u-boot-dtb.imx
85 setexpr blkcnt ${filesize} + 0x1ff && setexpr blkcnt ${blkcnt} / 0x200
86 mmc dev 0 1
87 mmc write ${loadaddr} 0x0 ${blkcnt}
Marcel Ziswiler4d1fea92023-08-29 00:01:53 +020088
89As a convenience, instead of the last three commands, one may also use the
90update U-Boot wrapper:
91
92.. code-block:: bash
93
94 > run update_uboot