blob: bdc4d0c2cb5a4aa32babce7e138a23ca048ce51d [file] [log] [blame]
Marcel Ziswiler2bc2f812022-02-07 11:54:13 +01001.. SPDX-License-Identifier: GPL-2.0-or-later
Marcel Ziswiler636acb42023-08-07 01:44:46 +02002.. sectionauthor:: Marcel Ziswiler <marcel.ziswiler@toradex.com>
Marcel Ziswiler2bc2f812022-02-07 11:54:13 +01003
4Verdin iMX8M Plus Module
5========================
6
Marcel Ziswiler636acb42023-08-07 01:44:46 +02007- SoM: https://www.toradex.com/computer-on-modules/verdin-arm-family/nxp-imx-8m-plus
8- Carrier board: https://www.toradex.com/products/carrier-board/verdin-development-board-kit
9
Marcel Ziswiler2bc2f812022-02-07 11:54:13 +010010Quick Start
11-----------
12
13- Build the ARM trusted firmware binary
14- Get the DDR firmware
15- Build U-Boot
16- Flash to eMMC
17- Boot
18
19Get and Build the ARM Trusted Firmware (Trusted Firmware A)
20-----------------------------------------------------------
21
22.. code-block:: bash
23
24 $ echo "Downloading and building TF-A..."
25 $ git clone https://git.trustedfirmware.org/TF-A/trusted-firmware-a.git
26 $ cd trusted-firmware-a
27
28Then build ATF (TF-A):
29
30.. code-block:: bash
31
32 $ export CROSS_COMPILE=aarch64-linux-gnu-
33 $ make PLAT=imx8mp IMX_BOOT_UART_BASE=0x30880000 bl31
34 $ cp build/imx8mp/release/bl31.bin ../
35
36Get the DDR Firmware
37--------------------
38
39.. code-block:: bash
40
41 $ cd ..
42 $ wget https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/firmware-imx-8.10.1.bin
43 $ chmod +x firmware-imx-8.10.1.bin
44 $ ./firmware-imx-8.10.1.bin
45 $ cp firmware-imx-8.10.1/firmware/ddr/synopsys/lpddr4*_202006.bin ./
46
47Build U-Boot
48------------
49.. code-block:: bash
50
51 $ export CROSS_COMPILE=aarch64-linux-gnu-
52 $ make verdin-imx8mp_defconfig
53 $ make
54
55Flash to eMMC
56-------------
57
58.. code-block:: bash
59
60 > tftpboot ${loadaddr} flash.bin
61 > setexpr blkcnt ${filesize} + 0x1ff && setexpr blkcnt ${blkcnt} / 0x200
62 > mmc dev 2 1 && mmc write ${loadaddr} 0x0 ${blkcnt}
63
64As a convenience, instead of the last two commands one may also use the update
65U-Boot wrapper:
66
67.. code-block:: bash
68
69 > run update_uboot
70
71Boot
72----
73
74ATF, U-Boot proper and u-boot.dtb images are packed into FIT image,
75which is loaded and parsed by SPL.
76
77Boot sequence is:
78
79* SPL ---> ATF (TF-A) ---> U-Boot proper
80
81Output:
82
Marcel Ziswiler636acb42023-08-07 01:44:46 +020083.. code-block:: none
Marcel Ziswiler2bc2f812022-02-07 11:54:13 +010084
Marcel Ziswiler636acb42023-08-07 01:44:46 +020085 U-Boot SPL 2022.04-rc1-00164-g21a0312611-dirty (Feb 07 2022 - 11:34:04 +0100)
86 Quad die, dual rank failed, attempting dual die, single rank configuration.
87 Normal Boot
88 WDT: Started watchdog@30280000 with servicing (60s timeout)
89 Trying to boot from BOOTROM
90 Find img info 0x&48025a00, size 872
91 Need continue download 1024
92 Download 779264, Total size 780424
93 NOTICE: BL31: v2.2(release):rel_imx_5.4.70_2.3.2_rc1-5-g835a8f67b
94 NOTICE: BL31: Built : 16:52:37, Aug 26 2021
Marcel Ziswiler2bc2f812022-02-07 11:54:13 +010095
96
Marcel Ziswiler636acb42023-08-07 01:44:46 +020097 U-Boot 2022.04-rc1-00164-g21a0312611-dirty (Feb 07 2022 - 11:34:04 +0100)
Marcel Ziswiler2bc2f812022-02-07 11:54:13 +010098
Marcel Ziswiler636acb42023-08-07 01:44:46 +020099 CPU: Freescale i.MX8MP[8] rev1.1 at 1200 MHz
100 Reset cause: POR
101 DRAM: 8 GiB
102 Core: 78 devices, 18 uclasses, devicetree: separate
103 WDT: Started watchdog@30280000 with servicing (60s timeout)
104 MMC: FSL_SDHC: 1, FSL_SDHC: 2
105 Loading Environment from MMC... OK
106 In: serial
107 Out: serial
108 Err: serial
109 Model: Toradex Verdin iMX8M Plus Quad 4GB Wi-Fi / BT IT V1.0B, Serial# 06817281
110 Carrier: Toradex Verdin Development Board V1.1A, Serial# 10807609
111 Setting variant to wifi
112 Net: Hard-coding pdata->enetaddr
113 eth1: ethernet@30be0000, eth0: ethernet@30bf0000 [PRIME]
114 Hit any key to stop autoboot: 0
115 Verdin iMX8MP #