Skip to contentSkip to conversation

imx: support for conga-QMX8 board

PATCH New Oliver Graute 2 participants 2 messages May 31, 2021 – Jun 9, 2021

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH v7 1/1 imx: support for conga-QMX8 board

Add i.MX8QM qmx8 congatec board support

U-Boot 2021.07-rc3-00528-gc9a966d9dd (May 31 2021 - 15:21:25 +0200)

CPU: NXP i.MX8QM RevB A53 at 1200 MHz

Model: Congatec QMX8 Qseven series
Board: conga-QMX8
Build: SCFW 494c97f3, SECO-FW d63fdb21, ATF 09c5cc9
Boot:  SD2
DRAM:  6 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
Loading Environment from MMC... OK
In:    serial@5a060000
Out:   serial@5a060000
Err:   serial@5a060000

switch to partitions #0, OK
mmc2 is current device
Net:
Error: ethernet@5b040000 address not set.
No ethernet found.

Hit any key to stop autoboot: 0

Cc Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Peng Fan <[email protected]>
Cc Simon Glass <[email protected]>
Cc uboot-imx <[email protected]>

---

These changes are based on this vendor tree:
git.congatec.com/imx8_early_access/imx8_uboot_internal.git

Changes for v7:
- removed superflous include in board/congatec/common/mmc.c
- added congatec to doc/board/index.rst

Changes for v6:
- fixed build warnings because of missing prototypes

Changes for v5:
- fixed checkpatch errors
- fixed some checkpatch warnings

Changes for v4:
- fixed missing DTS file in MAINTAINERS
- replaced bd_t with struct bd_info
- replaced README with imx8qm-dmsse20-a1.rst
- move CMD_FUSE to Kconfig
- replaced power_domain_lookup_name with imx8_power_domain_lookup_name

Changes for v3:
- include log.h
- include delay.h
- improved README
- set phy register to six
- Remove 'fdt_high' and 'initrd_high' environment variables
- set CONFIG_SYS_BOOTMAPSZ to 256MB
- increased CONFIG_SYS_FSL_USDHC_NUM to 3

Changes for v2:
- added USDHC3_BASE_ADDR
- replaced CONFIG_FSL_ESDHC with CONFIG_FSL_ESDHC_IMX
- set CONFIG_FEC_MXC_PHYADDR to -1
- moved CONFIG_ENV_SIZE and CONFIG_ENV_OFFSET to defconfig

 arch/arm/dts/Makefile               |   1 +
 arch/arm/dts/imx8qm-cgtqmx8.dts     | 404 ++++++++++++++++++++++++
 arch/arm/mach-imx/imx8/Kconfig      |   7 +
 board/congatec/cgtqmx8/Kconfig      |  14 +
 board/congatec/cgtqmx8/MAINTAINERS  |   7 +
 board/congatec/cgtqmx8/Makefile     |  11 +
 board/congatec/cgtqmx8/cgtqmx8.c    | 460 ++++++++++++++++++++++++++++
 board/congatec/cgtqmx8/imximage.cfg |  21 ++
 board/congatec/cgtqmx8/spl.c        |  77 +++++
 board/congatec/common/Kconfig       |  48 +++
 board/congatec/common/Makefile      |  23 ++
 board/congatec/common/mmc.c         |  49 +++
 configs/cgtqmx8_defconfig           |  86 ++++++
 doc/board/congatec/cgtqmx8.rst      |  70 +++++
 doc/board/congatec/index.rst        |   9 +
 doc/board/index.rst                 |   1 +
 include/configs/cgtqmx8.h           | 181 +++++++++++
 17 files changed, 1469 insertions(+)
 create mode 100644 arch/arm/dts/imx8qm-cgtqmx8.dts
 create mode 100644 board/congatec/cgtqmx8/Kconfig
 create mode 100644 board/congatec/cgtqmx8/MAINTAINERS
 create mode 100644 board/congatec/cgtqmx8/Makefile
 create mode 100644 board/congatec/cgtqmx8/cgtqmx8.c
 create mode 100644 board/congatec/cgtqmx8/imximage.cfg
 create mode 100644 board/congatec/cgtqmx8/spl.c
 create mode 100644 board/congatec/common/Kconfig
 create mode 100644 board/congatec/common/Makefile
 create mode 100644 board/congatec/common/mmc.c
 create mode 100644 configs/cgtqmx8_defconfig
 create mode 100644 doc/board/congatec/cgtqmx8.rst
 create mode 100644 doc/board/congatec/index.rst
 create mode 100644 include/configs/cgtqmx8.h
arch/arm/dts/Makefile +1 -0
index 096068261d..b95960c704 100644
@@ -836,6 +836,7 @@ dtb-$(CONFIG_ARCH_MX7ULP) += imx7ulp-com.dtb \
 dtb-$(CONFIG_ARCH_IMX8) += \
 	fsl-imx8qm-apalis.dtb \
 	fsl-imx8qm-mek.dtb \
+	imx8qm-cgtqmx8.dtb \
 	imx8qm-rom7720-a1.dtb \
 	fsl-imx8qxp-ai_ml.dtb \
 	fsl-imx8qxp-colibri.dtb \
arch/arm/dts/imx8qm-cgtqmx8.dts new file +404 -0

404 lines not on this page · raw message

arch/arm/mach-imx/imx8/Kconfig +7 -0
index 4e76612d05..71221d8d06 100644
@@ -86,6 +86,12 @@ config TARGET_IMX8QM_MEK
 	select BOARD_LATE_INIT
 	select IMX8QM
 
+config TARGET_CONGA_QMX8
+	bool "Support congatec conga-QMX8 board"
+	select BOARD_LATE_INIT
+	select SUPPORT_SPL
+	select IMX8QM
+
 config TARGET_IMX8QM_ROM7720_A1
 	bool "Support i.MX8QM ROM-7720-A1"
 	select BOARD_LATE_INIT
@@ -101,6 +107,7 @@ endchoice
 
 source "board/freescale/imx8qm_mek/Kconfig"
 source "board/freescale/imx8qxp_mek/Kconfig"
+source "board/congatec/cgtqmx8/Kconfig"
 source "board/advantech/imx8qm_rom7720_a1/Kconfig"
 source "board/toradex/apalis-imx8/Kconfig"
 source "board/toradex/colibri-imx8x/Kconfig"
board/congatec/cgtqmx8/Kconfig new file +14 -0
new file mode 100644
index 0000000000..7273039261
@@ -0,0 +1,14 @@
+if TARGET_CONGA_QMX8
+
+config SYS_BOARD
+	default "cgtqmx8"
+
+config SYS_VENDOR
+	default "congatec"
+
+config SYS_CONFIG_NAME
+	default "cgtqmx8"
+
+source "board/congatec/common/Kconfig"
+
+endif
board/congatec/cgtqmx8/MAINTAINERS new file +7 -0
new file mode 100644
index 0000000000..53bc0f93b7
@@ -0,0 +1,7 @@
+i.MX8QM CGTQMX8 BOARD
+M:	Oliver Graute <[email protected]>
+S:	Maintained
+F:	board/congatec/cgtqmx8/
+F:	arch/arm/dts/imx8qm-cgtqmx8.dts
+F:	include/configs/cgtqmx8.h
+F:	configs/cgtqmx8_defconfig
board/congatec/cgtqmx8/Makefile new file +11 -0
new file mode 100644
index 0000000000..4b59dbb6bc
@@ -0,0 +1,11 @@
+#
+# Copyright 2017 NXP
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+obj-y += cgtqmx8.o
+
+ifdef CONFIG_SPL_BUILD
+obj-y += spl.o
+endif
board/congatec/cgtqmx8/cgtqmx8.c new file +460 -0

460 lines not on this page · raw message

board/congatec/cgtqmx8/imximage.cfg new file +21 -0
new file mode 100644
index 0000000000..e324c7ca37
@@ -0,0 +1,21 @@
+/* SPDX-License-Identifier:	GPL-2.0+ */
+/*
+ * Copyright 2018 NXP
+ */
+
+#define __ASSEMBLY__
+
+/* Boot from SD, sector size 0x400 */
+BOOT_FROM SD 0x400
+/* SoC type IMX8QM */
+SOC_TYPE IMX8QM
+/* Append seco container image */
+APPEND mx8qm-ahab-container.img
+/* Create the 2nd container */
+CONTAINER
+/* Add scfw image with exec attribute */
+IMAGE SCU mx8qm-val-scfw-tcm.bin
+/* Add ATF image with exec attribute */
+IMAGE A35 bl31.bin 0x80000000
+/* Add U-Boot image with load attribute */
+DATA A35 u-boot-dtb.bin 0x80020000
board/congatec/cgtqmx8/spl.c new file +77 -0

77 lines not on this page · raw message

board/congatec/common/Kconfig new file +48 -0

48 lines not on this page · raw message

board/congatec/common/Makefile new file +23 -0
new file mode 100644
index 0000000000..d4ddfbf971
@@ -0,0 +1,23 @@
+#
+# (C) Copyright 2006
+# Wolfgang Denk, DENX Software Engineering, [email protected].
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+MINIMAL=
+
+ifdef CONFIG_SPL_BUILD
+ifdef CONFIG_SPL_INIT_MINIMAL
+MINIMAL=y
+endif
+endif
+
+ifdef MINIMAL
+# necessary to create built-in.o
+obj- := __dummy__.o
+else
+
+obj-y				+= mmc.o
+
+endif
board/congatec/common/mmc.c new file +49 -0

49 lines not on this page · raw message

configs/cgtqmx8_defconfig new file +86 -0

86 lines not on this page · raw message

doc/board/congatec/cgtqmx8.rst new file +70 -0

70 lines not on this page · raw message

doc/board/congatec/index.rst new file +9 -0
new file mode 100644
index 0000000000..cc57b36b2e
@@ -0,0 +1,9 @@
+.. SPDX-License-Identifier: GPL-2.0+
+
+Congatec
+========
+
+.. toctree::
+   :maxdepth: 2
+
+   cgtqmx8.rst
doc/board/index.rst +1 -0
index a70d2de19d..747511f7dd 100644
@@ -11,6 +11,7 @@ Board-specific doc
    AndesTech/index
    amlogic/index
    atmel/index
+   congatec/index
    coreboot/index
    emulation/index
    freescale/index
include/configs/cgtqmx8.h new file +181 -0

181 lines not on this page · raw message

Signature · 1 line
2.17.1
#1 lore raw

PATCH v7 1/1 imx: support for conga-QMX8 board

Quoted 19 lines

Add i.MX8QM qmx8 congatec board support
U-Boot 2021.07-rc3-00528-gc9a966d9dd (May 31 2021 - 15:21:25 +0200)

CPU:   NXP i.MX8QM RevB A53 at 1200 MHz
Model: Congatec QMX8 Qseven series
Board: conga-QMX8
Build: SCFW 494c97f3, SECO-FW d63fdb21, ATF 09c5cc9
Boot:  SD2
DRAM:  6 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
Loading Environment from MMC... OK
In:    serial@5a060000
Out:   serial@5a060000
Err:   serial@5a060000

switch to partitions #0, OK
mmc2 is current device
Net:
Error: ethernet@5b040000 address not set.
No ethernet found.
Hit any key to stop autoboot: 0

Quoted 7 lines
Cc Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Peng Fan <[email protected]>
Cc Simon Glass <[email protected]>
Cc uboot-imx <[email protected]>

Applied to u-boot-imx, master, thanks !

Best regards,
Stefano Babic

Signature · 5 lines
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: [email protected]
=====================================================================