Skip to contentSkip to conversation

colibri imx8qxp 2gb wb it v1.0b module support

PATCH New Marcel Ziswiler 2 participants 5 messages May 31, 2019 – Jun 10, 2019

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

v7 cover colibri imx8qxp 2gb wb it v1.0b module support

This series fixes building for i.MX8 without SPL and last but not least introduces support for the Toradex Colibri iMX8QXP 2GB WB IT V1.0B module.

This series is available together with the last few clean-up patches on our git server [1] as well.

[1] http://git.toradex.com/cgit/u-boot-toradex.git/log/?h=for-next

Changes in v7:
- no longer explicitly disable CONFIG_CMD_CRC32, CONFIG_CMD_EXPORTENV, CONFIG_CMD_IMLS and CONFIG_CMD_IMPORTENV
- increase max gunzip size (CONFIG_SYS_BOOTM_LEN) to 64 MB
- enable CONFIG_IMX_SCU_THERMAL
- rename board file and folder to more generic colibri-imx8x to be used for all SKUs
- just exclusively use distro_bootcmd trying SD card before eMMC
- enable FDT relocation
- added update_uboot helper wrapper as internally suggested by Igor

Changes in v6:
- Use firmware-imx-8.0 matching NXP's sumo-4.14.78-1.0.0_ga BSP as suggested by Max during review of Apalis iMX8QM.
- Drop anyway commented out board_gpio_init() stuff.
- Drop Qualcomm (formwerly Atheros) AR8031 specific board_phy_config() stuff not applicable to the Micrel PHY we are using as suggested by Max during review of Apalis iMX8QM.

Changes in v5:
- Keep alphabetical order of device trees in Makefile.
- Order targets in Kconfig alphabetically.
- Fix indentation in SPDX.
- Remove stale includes from board file.
- Take into account ahab-container being platform specific.
- Use vidargs instead of multiple discrete video= in configuration.
- Fix console baudrate specification.
- Remove redundant CONFIG_SYS_MMC_ENV_DEV define and add some clarifying comment.
- Fix product name being Colibri iMX8X in a comment.
- Remove obsolete CONFIG_NR_DRAM_BANKS.

Changes in v4:
- Fixed SPDX as well as using SZ_ macros where applicable as suggested by Igor.
- Fixed superfluous trailing line continuation introduced by commit 0d331c035a09 ("imx: support i.MX8QM MEK board") in the Makefile plus sorted stuff alphabetically again.
- Applied changes similar to commit 3b9ac5415084 ("imx: 8qxp_mek: fix fdt_file and console"). However, note that using ${baudrate} in console= like that won't actually work!
- Applied changes similar to commit e5b8f7e665aa ("imx8qxp: mek: enable dm-spl for pm").

Changes in v3:
- Added Igor's reviewed-by tag.

Changes in v2:
- Changed imx-atf git clone command to include initial branch information as suggested by Igor.
- Sorted board file includes alphabetically as suggested by Igor.
- Got rid of SPL configuration in legacy header file as suggested by Igor and the whole use of SPL on i.MX 8X anyway neither works well nor makes any much sense at all.

Marcel Ziswiler (2):
imx: fix building for i.mx8 without spl
board: toradex: add colibri imx8qxp 2gb wb it v1.0b module support

 arch/arm/dts/Makefile                         |   3 +-
 arch/arm/dts/fsl-imx8qxp-colibri-u-boot.dtsi  | 117 +++++++
 arch/arm/dts/fsl-imx8qxp-colibri.dts          | 328 ++++++++++++++++++
 arch/arm/mach-imx/Makefile                    |   2 +
 arch/arm/mach-imx/imx8/Kconfig                |  12 +-
 board/toradex/colibri-imx8x/Kconfig           |  30 ++
 board/toradex/colibri-imx8x/MAINTAINERS       |   9 +
 board/toradex/colibri-imx8x/Makefile          |   6 +
 board/toradex/colibri-imx8x/README            |  66 ++++
 .../colibri-imx8qxp-imximage.cfg              |  24 ++
 board/toradex/colibri-imx8x/colibri-imx8x.c   | 160 +++++++++
 configs/colibri-imx8qxp_defconfig             |  54 +++
 include/configs/colibri-imx8x.h               | 165 +++++++++
 13 files changed, 972 insertions(+), 4 deletions(-)
 create mode 100644 arch/arm/dts/fsl-imx8qxp-colibri-u-boot.dtsi
 create mode 100644 arch/arm/dts/fsl-imx8qxp-colibri.dts
 create mode 100644 board/toradex/colibri-imx8x/Kconfig
 create mode 100644 board/toradex/colibri-imx8x/MAINTAINERS
 create mode 100644 board/toradex/colibri-imx8x/Makefile
 create mode 100644 board/toradex/colibri-imx8x/README
 create mode 100644 board/toradex/colibri-imx8x/colibri-imx8qxp-imximage.cfg
 create mode 100644 board/toradex/colibri-imx8x/colibri-imx8x.c
 create mode 100644 configs/colibri-imx8qxp_defconfig
 create mode 100644 include/configs/colibri-imx8x.h
Signature · 1 line
2.21.0
#1 lore raw

PATCH v7 1/2 imx: fix building for i.mx8 without spl

From: Marcel Ziswiler <[email protected]>

Building with Travis CI complained and stopped with the following error:
+cc1: fatal error: opening output file spl/u-boot-spl.cfgout: No such file or directory
+compilation terminated.

This fixes commit caceb739ea07 ("imx: build flash.bin for i.MX8") which took SPL being enabled on i.MX8 for granted.

---

Changes in v7: None
Changes in v6: None
Changes in v5: None
Changes in v4: None
Changes in v3: None
Changes in v2: None

 arch/arm/mach-imx/Makefile | 2 ++
 1 file changed, 2 insertions(+)
arch/arm/mach-imx/Makefile +2 -0
index 37675d0558..6531c67fc6 100644
@@ -107,7 +107,9 @@ IMX_CONFIG = $(CONFIG_IMX_CONFIG:"%"=%)
 ifeq ($(CONFIG_ARCH_IMX8), y)
 CNTR_DEPFILES := $(srctree)/tools/imx_cntr_image.sh
 IMAGE_TYPE := imx8image
+ifeq ($(CONFIG_SPL_BUILD),y)
 SPL_DEPFILE_EXISTS := $(shell $(CPP) $(cpp_flags) -x c -o spl/u-boot-spl.cfgout $(srctree)/$(IMX_CONFIG); if [ -f spl/u-boot-spl.cfgout ]; then $(CNTR_DEPFILES) spl/u-boot-spl.cfgout; echo $$?; fi)
+endif
 DEPFILE_EXISTS := $(shell $(CPP) $(cpp_flags) -x c -o u-boot-dtb.cfgout $(srctree)/$(IMX_CONFIG); if [ -f u-boot-dtb.cfgout ]; then $(CNTR_DEPFILES) u-boot-dtb.cfgout; echo $$?; fi)
 else ifeq ($(CONFIG_ARCH_IMX8M), y)
 IMAGE_TYPE := imx8mimage
Signature · 1 line
2.21.0
#2 lore raw

PATCH v7 1/2 imx: fix building for i.mx8 without spl

Quoted 10 lines

From: Marcel Ziswiler <[email protected]>
Building with Travis CI complained and stopped with the following error:
+cc1: fatal error: opening output file spl/u-boot-spl.cfgout: No such file or directory
+compilation terminated.
This fixes commit caceb739ea07 ("imx: build flash.bin for i.MX8") which took SPL being enabled on i.MX8 for granted.

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: sbabic at denx.de
=====================================================================
#3 lore raw

PATCH v7 2/2 board: toradex: add colibri imx8qxp 2gb wb it v1.0b module support

In reply to Marcel Ziswiler

From: Marcel Ziswiler <[email protected]>

This commit adds initial support for the Toradex Colibri iMX8QXP 2GB WB IT V1.0B module. Unlike the V1.0A early access samples exclusively booting from SD card, they are now strapped to boot from eFuses which are factory fused to properly boot from their on-module eMMC. U-Boot supports either booting from the on-module eMMC or may be used for recovery purpose using the universal update utility (uuu) aka mfgtools 3.0.

Functionality wise the following is known to be working:
- eMMC and MMC/SD card
- Ethernet
- GPIOs
- I2C

Unfortunately, there is no USB functionality for the i.MX 8QXP as of yet.

---

Changes in v7:
- no longer explicitly disable CONFIG_CMD_CRC32, CONFIG_CMD_EXPORTENV, CONFIG_CMD_IMLS and CONFIG_CMD_IMPORTENV
- increase max gunzip size (CONFIG_SYS_BOOTM_LEN) to 64 MB
- enable CONFIG_IMX_SCU_THERMAL
- rename board file and folder to more generic colibri-imx8x to be used for all SKUs
- just exclusively use distro_bootcmd trying SD card before eMMC
- enable FDT relocation
- added update_uboot helper wrapper as internally suggested by Igor

Changes in v6:
- Use firmware-imx-8.0 matching NXP's sumo-4.14.78-1.0.0_ga BSP as suggested by Max during review of Apalis iMX8QM.
- Drop anyway commented out board_gpio_init() stuff.
- Drop Qualcomm (formwerly Atheros) AR8031 specific board_phy_config() stuff not applicable to the Micrel PHY we are using as suggested by Max during review of Apalis iMX8QM.

Changes in v5:
- Keep alphabetical order of device trees in Makefile.
- Order targets in Kconfig alphabetically.
- Fix indentation in SPDX.
- Remove stale includes from board file.
- Take into account ahab-container being platform specific.
- Use vidargs instead of multiple discrete video= in configuration.
- Fix console baudrate specification.
- Remove redundant CONFIG_SYS_MMC_ENV_DEV define and add some clarifying comment.
- Fix product name being Colibri iMX8X in a comment.
- Remove obsolete CONFIG_NR_DRAM_BANKS.

Changes in v4:
- Fixed SPDX as well as using SZ_ macros where applicable as suggested by Igor.
- Fixed superfluous trailing line continuation introduced by commit 0d331c035a09 ("imx: support i.MX8QM MEK board") in the Makefile plus sorted stuff alphabetically again.
- Applied changes similar to commit 3b9ac5415084 ("imx: 8qxp_mek: fix fdt_file and console"). However, note that using ${baudrate} in console= like that won't actually work!
- Applied changes similar to commit e5b8f7e665aa ("imx8qxp: mek: enable dm-spl for pm").

Changes in v3:
- Added Igor's reviewed-by tag.

Changes in v2:
- Changed imx-atf git clone command to include initial branch information as suggested by Igor.
- Sorted board file includes alphabetically as suggested by Igor.
- Got rid of SPL configuration in legacy header file as suggested by Igor and the whole use of SPL on i.MX 8X anyway neither works well nor makes any much sense at all.

 arch/arm/dts/Makefile                         |   3 +-
 arch/arm/dts/fsl-imx8qxp-colibri-u-boot.dtsi  | 117 +++++++
 arch/arm/dts/fsl-imx8qxp-colibri.dts          | 328 ++++++++++++++++++
 arch/arm/mach-imx/imx8/Kconfig                |  12 +-
 board/toradex/colibri-imx8x/Kconfig           |  30 ++
 board/toradex/colibri-imx8x/MAINTAINERS       |   9 +
 board/toradex/colibri-imx8x/Makefile          |   6 +
 board/toradex/colibri-imx8x/README            |  66 ++++
 .../colibri-imx8qxp-imximage.cfg              |  24 ++
 board/toradex/colibri-imx8x/colibri-imx8x.c   | 160 +++++++++
 configs/colibri-imx8qxp_defconfig             |  54 +++
 include/configs/colibri-imx8x.h               | 165 +++++++++
 12 files changed, 970 insertions(+), 4 deletions(-)
 create mode 100644 arch/arm/dts/fsl-imx8qxp-colibri-u-boot.dtsi
 create mode 100644 arch/arm/dts/fsl-imx8qxp-colibri.dts
 create mode 100644 board/toradex/colibri-imx8x/Kconfig
 create mode 100644 board/toradex/colibri-imx8x/MAINTAINERS
 create mode 100644 board/toradex/colibri-imx8x/Makefile
 create mode 100644 board/toradex/colibri-imx8x/README
 create mode 100644 board/toradex/colibri-imx8x/colibri-imx8qxp-imximage.cfg
 create mode 100644 board/toradex/colibri-imx8x/colibri-imx8x.c
 create mode 100644 configs/colibri-imx8qxp_defconfig
 create mode 100644 include/configs/colibri-imx8x.h
arch/arm/dts/Makefile +2 -1
index f887d99393..ae62fbcbc2 100644
@@ -603,8 +603,9 @@ dtb-$(CONFIG_MX7) += imx7d-sdb.dtb \
 dtb-$(CONFIG_ARCH_MX7ULP) += imx7ulp-evk.dtb
 
 dtb-$(CONFIG_ARCH_IMX8) += \
-	fsl-imx8qxp-mek.dtb \
 	fsl-imx8qm-mek.dtb \
+	fsl-imx8qxp-colibri.dtb \
+	fsl-imx8qxp-mek.dtb
 
 dtb-$(CONFIG_ARCH_IMX8M) += fsl-imx8mq-evk.dtb
 
arch/arm/dts/fsl-imx8qxp-colibri-u-boot.dtsi new file +117 -0

117 lines not on this page · raw message

arch/arm/dts/fsl-imx8qxp-colibri.dts new file +328 -0

328 lines not on this page · raw message

arch/arm/mach-imx/imx8/Kconfig +9 -3
index c32f7dbb61..385000775c 100644
@@ -27,8 +27,8 @@ choice
 	prompt "i.MX8 board select"
 	optional
 
-config TARGET_IMX8QXP_MEK
-	bool "Support i.MX8QXP MEK board"
+config TARGET_COLIBRI_IMX8X
+	bool "Support Colibri iMX8X module"
 	select BOARD_LATE_INIT
 	select IMX8QXP
 
@@ -37,9 +37,15 @@ config TARGET_IMX8QM_MEK
 	select BOARD_LATE_INIT
 	select IMX8QM
 
+config TARGET_IMX8QXP_MEK
+	bool "Support i.MX8QXP MEK board"
+	select BOARD_LATE_INIT
+	select IMX8QXP
+
 endchoice
 
-source "board/freescale/imx8qxp_mek/Kconfig"
 source "board/freescale/imx8qm_mek/Kconfig"
+source "board/freescale/imx8qxp_mek/Kconfig"
+source "board/toradex/colibri-imx8x/Kconfig"
 
 endif
board/toradex/colibri-imx8x/Kconfig new file +30 -0
new file mode 100644
index 0000000000..d97fed020e
@@ -0,0 +1,30 @@
+if TARGET_COLIBRI_IMX8X
+
+config SYS_BOARD
+	default "colibri-imx8x"
+
+config SYS_VENDOR
+	default "toradex"
+
+config SYS_CONFIG_NAME
+	default "colibri-imx8x"
+
+config TDX_CFG_BLOCK
+	default y
+
+config TDX_HAVE_MMC
+	default y
+
+config TDX_CFG_BLOCK_DEV
+	default "0"
+
+config TDX_CFG_BLOCK_PART
+	default "1"
+
+# Toradex config block in eMMC, at the end of 1st "boot sector"
+config TDX_CFG_BLOCK_OFFSET
+	default "-512"
+
+source "board/toradex/common/Kconfig"
+
+endif
board/toradex/colibri-imx8x/MAINTAINERS new file +9 -0
new file mode 100644
index 0000000000..e91b9975c2
@@ -0,0 +1,9 @@
+Colibri iMX8X
+M:	Marcel Ziswiler <[email protected]>
+W:	http://developer.toradex.com/software/linux/linux-software
+S:	Maintained
+F:	arch/arm/dts/fsl-imx8x-colibri.dts
+F:	arch/arm/dts/fsl-imx8x-colibri-u-boot.dtsi
+F:	board/toradex/colibri-imx8x/
+F:	configs/colibri-imx8qxp_defconfig
+F:	include/configs/colibri-imx8x.h
board/toradex/colibri-imx8x/Makefile new file +6 -0
new file mode 100644
index 0000000000..e3945c8f15
@@ -0,0 +1,6 @@
+# SPDX-License-Identifier: GPL-2.0+
+#
+# Copyright 2019 Toradex
+#
+
+obj-y += colibri-imx8x.o
board/toradex/colibri-imx8x/README new file +66 -0

66 lines not on this page · raw message

board/toradex/colibri-imx8x/colibri-imx8qxp-imximage.cfg new file +24 -0
new file mode 100644
index 0000000000..1dcd13271d
@@ -0,0 +1,24 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright 2019 Toradex
+ *
+ * Refer doc/README.imx8image for more details about how-to configure
+ * and create imx8image boot image
+ */
+
+#define __ASSEMBLY__
+
+/* Boot from SD, sector size 0x400 */
+BOOT_FROM EMMC_FASTBOOT 0x400
+/* SoC type IMX8QX */
+SOC_TYPE IMX8QX
+/* Append seco container image */
+APPEND mx8qx-ahab-container.img
+/* Create the 2nd container */
+CONTAINER
+/* Add scfw image with exec attribute */
+IMAGE SCU mx8qx-colibri-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/toradex/colibri-imx8x/colibri-imx8x.c new file +160 -0

160 lines not on this page · raw message

configs/colibri-imx8qxp_defconfig new file +54 -0

54 lines not on this page · raw message

include/configs/colibri-imx8x.h new file +165 -0

165 lines not on this page · raw message

Signature · 1 line
2.21.0
#4 lore raw

PATCH v7 2/2 board: toradex: add colibri imx8qxp 2gb wb

Quoted 15 lines

From: Marcel Ziswiler <[email protected]>
This commit adds initial support for the Toradex Colibri iMX8QXP 2GB WB IT V1.0B module. Unlike the V1.0A early access samples exclusively booting from SD card, they are now strapped to boot from eFuses which are factory fused to properly boot from their on-module eMMC. U-Boot supports either booting from the on-module eMMC or may be used for recovery purpose using the universal update utility (uuu) aka mfgtools 3.0.
Functionality wise the following is known to be working:
- eMMC and MMC/SD card
- Ethernet
- GPIOs
- I2C
Unfortunately, there is no USB functionality for the i.MX 8QXP as of yet.

Quoted 2 lines

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: sbabic at denx.de
=====================================================================