Skip to contentSkip to conversation

i.MX8QM ROM 7720 a1 board won't boot

PATCH New Oliver Graute 3 participants 8 messages Aug 16, 2019 – Aug 19, 2019

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

cover i.MX8QM ROM 7720 a1 board won't boot

I'am currently working on the following patch to get the imx8qm-rom7720-a1 board working with recent u-boot v2019.07. Unfortunaly I get no output on my serial line.

I'am not sure if something in my patch is just missing or if my composition of "SCFW + ATF + uboot" which is necessary for this imx8qm board, is not working the right way.

Perhaps somebody can guide me in the right direction to debug this further.

Currently I'am applying the patch and building u-boot this way:

$ export ATF_LOAD_ADDR=0x80000000
$ export BL33_LOAD_ADDR=0x80020000
$ make imx8qm_rom7720_a1_4G_defconfig
$ make flash.bin
$ dd if=u-boot.itb of=flash.bin bs=512 seek=854
$ sudo dd if=flash.bin of=/dev/sd[x] bs=1k seek=32 conv=fsync

Then I put the SD card into the board and power it on. But no output ony my serial line.

Best Regards,

Oliver Graute (1):
imx: support i.MX8QM ROM 7720 a1 board

 arch/arm/dts/Makefile                         |   1 +
 arch/arm/dts/imx8qm-rom7720-a1.dts            | 373 ++++++++++++++++++
 arch/arm/mach-imx/imx8/Kconfig                |   7 +
 arch/arm/mach-imx/mkimage_fit_atf.sh          |   3 +
 board/freescale/imx8qm_rom7720_a1/Kconfig     |  14 +
 board/freescale/imx8qm_rom7720_a1/MAINTAINERS |   6 +
 board/freescale/imx8qm_rom7720_a1/Makefile    |  11 +
 board/freescale/imx8qm_rom7720_a1/README      |  53 +++
 .../imx8qm_rom7720_a1/imx8qm_rom7720_a1.c     | 181 +++++++++
 .../freescale/imx8qm_rom7720_a1/imximage.cfg  |  21 +
 board/freescale/imx8qm_rom7720_a1/spl.c       | 228 +++++++++++
 configs/imx8qm_rom7720_a1_4G_defconfig        |  77 ++++
 include/configs/imx8qm_rom7720.h              | 293 ++++++++++++++
 13 files changed, 1268 insertions(+)
 create mode 100644 arch/arm/dts/imx8qm-rom7720-a1.dts
 create mode 100644 board/freescale/imx8qm_rom7720_a1/Kconfig
 create mode 100644 board/freescale/imx8qm_rom7720_a1/MAINTAINERS
 create mode 100644 board/freescale/imx8qm_rom7720_a1/Makefile
 create mode 100644 board/freescale/imx8qm_rom7720_a1/README
 create mode 100644 board/freescale/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c
 create mode 100644 board/freescale/imx8qm_rom7720_a1/imximage.cfg
 create mode 100644 board/freescale/imx8qm_rom7720_a1/spl.c
 create mode 100644 configs/imx8qm_rom7720_a1_4G_defconfig
 create mode 100644 include/configs/imx8qm_rom7720.h
Signature · 1 line
2.17.1
#1 lore raw

PATCH 1/1 imx: support i.MX8QM ROM 7720 a1 board

Add i.MX8QM ROM 7720a1 board support

Cc Stefano Babic <[email protected]>
Cc Peng Fan <[email protected]>
Cc uboot-imx <[email protected]>

---

These changes are based on this vendor tree:
https://github.com/ADVANTECH-Corp/uboot-imx6.git

I adapted the files and compared them with code from similar imx8qm-mek board

 arch/arm/dts/Makefile                         |   1 +
 arch/arm/dts/imx8qm-rom7720-a1.dts            | 373 ++++++++++++++++++
 arch/arm/mach-imx/imx8/Kconfig                |   7 +
 arch/arm/mach-imx/mkimage_fit_atf.sh          |   3 +
 board/freescale/imx8qm_rom7720_a1/Kconfig     |  14 +
 board/freescale/imx8qm_rom7720_a1/MAINTAINERS |   6 +
 board/freescale/imx8qm_rom7720_a1/Makefile    |  11 +
 board/freescale/imx8qm_rom7720_a1/README      |  53 +++
 .../imx8qm_rom7720_a1/imx8qm_rom7720_a1.c     | 181 +++++++++
 .../freescale/imx8qm_rom7720_a1/imximage.cfg  |  21 +
 board/freescale/imx8qm_rom7720_a1/spl.c       | 228 +++++++++++
 configs/imx8qm_rom7720_a1_4G_defconfig        |  77 ++++
 include/configs/imx8qm_rom7720.h              | 293 ++++++++++++++
 13 files changed, 1268 insertions(+)
 create mode 100644 arch/arm/dts/imx8qm-rom7720-a1.dts
 create mode 100644 board/freescale/imx8qm_rom7720_a1/Kconfig
 create mode 100644 board/freescale/imx8qm_rom7720_a1/MAINTAINERS
 create mode 100644 board/freescale/imx8qm_rom7720_a1/Makefile
 create mode 100644 board/freescale/imx8qm_rom7720_a1/README
 create mode 100644 board/freescale/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c
 create mode 100644 board/freescale/imx8qm_rom7720_a1/imximage.cfg
 create mode 100644 board/freescale/imx8qm_rom7720_a1/spl.c
 create mode 100644 configs/imx8qm_rom7720_a1_4G_defconfig
 create mode 100644 include/configs/imx8qm_rom7720.h
arch/arm/dts/Makefile +1 -0
index 20dbc2ff84..54c1f40085 100644
@@ -613,6 +613,7 @@ dtb-$(CONFIG_ARCH_MX7ULP) += imx7ulp-evk.dtb
 dtb-$(CONFIG_ARCH_IMX8) += \
 	fsl-imx8qm-apalis.dtb \
 	fsl-imx8qm-mek.dtb \
+	imx8qm-rom7720-a1.dtb \
 	fsl-imx8qxp-colibri.dtb \
 	fsl-imx8qxp-mek.dtb
 
arch/arm/dts/imx8qm-rom7720-a1.dts new file +373 -0

373 lines not on this page · raw message

arch/arm/mach-imx/imx8/Kconfig +7 -0
index bbe323d5ca..09b985884f 100644
@@ -42,6 +42,12 @@ config TARGET_IMX8QM_MEK
 	select BOARD_LATE_INIT
 	select IMX8QM
 
+config TARGET_IMX8QM_ROM7720_A1
+	bool "Support i.MX8QM ROM-7720-A1"
+	select BOARD_LATE_INIT
+	select SUPPORT_SPL
+	select IMX8QM
+
 config TARGET_IMX8QXP_MEK
 	bool "Support i.MX8QXP MEK board"
 	select BOARD_LATE_INIT
@@ -50,6 +56,7 @@ config TARGET_IMX8QXP_MEK
 endchoice
 
 source "board/freescale/imx8qm_mek/Kconfig"
+source "board/freescale/imx8qm_rom7720_a1/Kconfig"
 source "board/freescale/imx8qxp_mek/Kconfig"
 source "board/toradex/apalis-imx8/Kconfig"
 source "board/toradex/colibri-imx8x/Kconfig"
arch/arm/mach-imx/mkimage_fit_atf.sh +3 -0
index 38c9858e84..75ac8e7ed2 100755
@@ -19,6 +19,9 @@ else
 	ls -lct $BL31 | awk '{print $5}' >&2
 fi
 
+echo "ATF_LOAD_ADDR=$ATF_LOAD_ADDR" >&2
+echo "BL33_LOAD_ADDR=$BL33_LOAD_ADDR" >&2
+
 BL32="tee.bin"
 
 if [ ! -f $BL32 ]; then
board/freescale/imx8qm_rom7720_a1/Kconfig new file +14 -0
new file mode 100644
index 0000000000..7041567d44
@@ -0,0 +1,14 @@
+if TARGET_IMX8QM_ROM7720_A1
+
+config SYS_BOARD
+	default "imx8qm_rom7720_a1"
+
+config SYS_VENDOR
+	default "freescale"
+
+config SYS_CONFIG_NAME
+	default "imx8qm_rom7720"
+
+source "board/freescale/common/Kconfig"
+
+endif
board/freescale/imx8qm_rom7720_a1/MAINTAINERS new file +6 -0
new file mode 100644
index 0000000000..c5553d5ad9
@@ -0,0 +1,6 @@
+i.MX8QM ROM 7720 a1 BOARD
+M:	Oliver Graute <[email protected]>
+S:	Maintained
+F:	board/freescale/imx8qm_rom7720_a1/
+F:	include/configs/imx8qm_rom7720.h
+F:	configs/imx8qm_rom7720_a1_4G_defconfig
board/freescale/imx8qm_rom7720_a1/Makefile new file +11 -0
new file mode 100644
index 0000000000..51c5de251c
@@ -0,0 +1,11 @@
+#
+# Copyright 2017 NXP
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+obj-y += imx8qm_rom7720_a1.o
+
+ifdef CONFIG_SPL_BUILD
+obj-y += spl.o
+endif
board/freescale/imx8qm_rom7720_a1/README new file +53 -0

53 lines not on this page · raw message

board/freescale/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c new file +181 -0

181 lines not on this page · raw message

board/freescale/imx8qm_rom7720_a1/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/freescale/imx8qm_rom7720_a1/spl.c new file +228 -0

228 lines not on this page · raw message

configs/imx8qm_rom7720_a1_4G_defconfig new file +77 -0

77 lines not on this page · raw message

include/configs/imx8qm_rom7720.h new file +293 -0

293 lines not on this page · raw message

Signature · 1 line
2.17.1
#2 lore raw

cover i.MX8QM ROM 7720 a1 board won't boot

In reply to Oliver Graute

Hi Oliver

Quoted 2 lines · Oliver Graute

I'am currently working on the following patch to get the imx8qm- rom7720-a1

That version sounds suspiciously like it may be based on initial alpha silicon from NXP which as far as I know is not supported anywhere any more. Not even in downstream.

If it has alpha silicon my suggestion is to throw it away and move on.

Quoted 1 line

board working with recent u-boot v2019.07.

v2019.07 has long since been released. So what you are talking about would be any future release like v2020.01 as even the v2019.10 merge window long since closed.

Quoted 2 lines

Unfortunaly I get no output on my
serial line.

Alpha chips came with different boot ROM requiring completely different SCFW as far as I know.

Quoted 5 lines

I'am not sure if something in my patch is just missing or if my composition of
"SCFW + ATF + uboot" which is necessary for this imx8qm board, is not working
the right way.

I am also wondering whether that hardware really does not require customised SCFW but rather relies on NXP's ancient since obsolete validation board one. If so it would need to be more or less fully identical to that hardware which I seriously doubt. Is that really the case?

Quoted 2 lines

Perhaps somebody can guide me in the right direction to debug this further.

To debug this one would probably need access to the SCU's tightly coupled UART aka SCU.UART0.RX/TX. Plus a special built SCFW that actually makes use of it. Do you have that?

BTW: NXP's latest SCFWKIT is version 1.2.2 while you still reference ancient version 1.1. More or less the whole world changed ever since.

Quoted 8 lines

Currently I'am applying the patch and building u-boot this way:

$ export ATF_LOAD_ADDR=0x80000000
$ export BL33_LOAD_ADDR=0x80020000
$ make imx8qm_rom7720_a1_4G_defconfig
$ make flash.bin
$ dd if=u-boot.itb of=flash.bin bs=512 seek=854
$ sudo dd if=flash.bin of=/dev/sd[x] bs=1k seek=32 conv=fsync

Well, meanwhile at least their MEKs NXP boots now via SPL. However, due to current incompatibility with their recovery tooling uuu at least we still boot our hardware without SPL but that would require building it differently e.g. see here:

https://gitlab.denx.de/u-boot/u-boot/blob/master/board/toradex/apalis-imx8/README

You may also be able to recovery boot it via serial downloader but that depends on fusing/strapping...

Quoted 7 lines

Then I put the SD card into the board and power it on. But no output ony my
serial line.

Best Regards,

Oliver Graute (1):

Cheers

Marcel

Quoted 28 lines

imx: support i.MX8QM ROM 7720 a1 board

 arch/arm/dts/Makefile                         |   1 +
 arch/arm/dts/imx8qm-rom7720-a1.dts            | 373
++++++++++++++++++
 arch/arm/mach-imx/imx8/Kconfig                |   7 +
 arch/arm/mach-imx/mkimage_fit_atf.sh          |   3 +
 board/freescale/imx8qm_rom7720_a1/Kconfig     |  14 +
 board/freescale/imx8qm_rom7720_a1/MAINTAINERS |   6 +
 board/freescale/imx8qm_rom7720_a1/Makefile    |  11 +
 board/freescale/imx8qm_rom7720_a1/README      |  53 +++
 .../imx8qm_rom7720_a1/imx8qm_rom7720_a1.c     | 181 +++++++++
 .../freescale/imx8qm_rom7720_a1/imximage.cfg  |  21 +
 board/freescale/imx8qm_rom7720_a1/spl.c       | 228 +++++++++++
 configs/imx8qm_rom7720_a1_4G_defconfig        |  77 ++++
 include/configs/imx8qm_rom7720.h              | 293 ++++++++++++++
 13 files changed, 1268 insertions(+)
 create mode 100644 arch/arm/dts/imx8qm-rom7720-a1.dts
 create mode 100644 board/freescale/imx8qm_rom7720_a1/Kconfig
 create mode 100644 board/freescale/imx8qm_rom7720_a1/MAINTAINERS
 create mode 100644 board/freescale/imx8qm_rom7720_a1/Makefile
 create mode 100644 board/freescale/imx8qm_rom7720_a1/README
 create mode 100644
board/freescale/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c
 create mode 100644 board/freescale/imx8qm_rom7720_a1/imximage.cfg
 create mode 100644 board/freescale/imx8qm_rom7720_a1/spl.c
 create mode 100644 configs/imx8qm_rom7720_a1_4G_defconfig
 create mode 100644 include/configs/imx8qm_rom7720.h
#3 lore raw

cover i.MX8QM ROM 7720 a1 board won't boot

Quoted 9 lines · Marcel Ziswiler

Hi Oliver

Quoted 2 lines · Oliver Graute

I'am currently working on the following patch to get the imx8qm- rom7720-a1

That version sounds suspiciously like it may be based on initial alpha silicon from NXP which as far as I know is not supported anywhere any more. Not even in downstream.

yes this board is alpha. But thats all I have right now :-p But with the vendor u-boot-imx the board is booting fine. So I assumed I could port and adapt the files and boot things up with newest released u-boot.

Quoted 8 lines

If it has alpha silicon my suggestion is to throw it away and move on.

Quoted 1 line

board working with recent u-boot v2019.07.

v2019.07 has long since been released. So what you are talking about would be any future release like v2020.01 as even the v2019.10 merge window long since closed.

I understood that for patch integration it takes some time.

Quoted 6 lines
Quoted 3 lines

Unfortunaly I get no output on my
serial line.

Alpha chips came with different boot ROM requiring completely different SCFW as far as I know.

Ok thats important info for me. Which I was not aware of.

Quoted 13 lines
Quoted 6 lines

I'am not sure if something in my patch is just missing or if my composition of
"SCFW + ATF + uboot" which is necessary for this imx8qm board, is not working
the right way.

I am also wondering whether that hardware really does not require customised SCFW but rather relies on NXP's ancient since obsolete validation board one. If so it would need to be more or less fully identical to that hardware which I seriously doubt. Is that really the case?

Quoted 6 lines
Quoted 2 lines

Perhaps somebody can guide me in the right direction to debug this further.

To debug this one would probably need access to the SCU's tightly coupled UART aka SCU.UART0.RX/TX. Plus a special built SCFW that actually makes use of it. Do you have that?

No, currently I don't have the possibility to debug it on this level.

Quoted 3 lines

BTW: NXP's latest SCFWKIT is version 1.2.2 while you still reference ancient version 1.1. More or less the whole world changed ever since.

Ok, I'll ask my vendor which scfwkit I need for my alpha board here.

Quoted 15 lines
Quoted 9 lines

Currently I'am applying the patch and building u-boot this way:

$ export ATF_LOAD_ADDR=0x80000000
$ export BL33_LOAD_ADDR=0x80020000
$ make imx8qm_rom7720_a1_4G_defconfig
$ make flash.bin
$ dd if=u-boot.itb of=flash.bin bs=512 seek=854
$ sudo dd if=flash.bin of=/dev/sd[x] bs=1k seek=32 conv=fsync

Well, meanwhile at least their MEKs NXP boots now via SPL. However, due to current incompatibility with their recovery tooling uuu at least we still boot our hardware without SPL but that would require building it differently e.g. see here:

Quoted 4 lines

https://gitlab.denx.de/u-boot/u-boot/blob/master/board/toradex/apalis-imx8/README

You may also be able to recovery boot it via serial downloader but that depends on fusing/strapping...

Thx for you comments,

Best regards,

Oliver

#4 lore raw

cover i.MX8QM ROM 7720 a1 board won't boot

In reply to Marcel Ziswiler
Quoted 18 lines · Marcel Ziswiler

Hi Oliver

Quoted 2 lines · Oliver Graute

I'am currently working on the following patch to get the imx8qm- rom7720-a1

That version sounds suspiciously like it may be based on initial alpha silicon from NXP which as far as I know is not supported anywhere any more. Not even in downstream.

If it has alpha silicon my suggestion is to throw it away and move on.

Quoted 1 line

board working with recent u-boot v2019.07.

v2019.07 has long since been released. So what you are talking about would be any future release like v2020.01 as even the v2019.10 merge window long since closed.

Quoted 5 lines
Quoted 2 lines

Unfortunaly I get no output on my
serial line.

Alpha chips came with different boot ROM requiring completely different SCFW as far as I know.

I have to correct myself. After some investigation I can say that I have the B-Silicium of imx8qm on this board. So should I rename everything from a1 to b1?

Best regards,

Oliver

#5 lore raw

cover i.MX8QM ROM 7720 a1 board won't boot

Quoted 24 lines

Subject: Re: [PATCH 0/1] i.MX8QM ROM 7720 a1 board won't boot

Quoted 21 lines · Marcel Ziswiler

Hi Oliver

Quoted 2 lines · Oliver Graute

I'am currently working on the following patch to get the imx8qm- rom7720-a1

That version sounds suspiciously like it may be based on initial alpha silicon from NXP which as far as I know is not supported anywhere any more. Not even in downstream.

If it has alpha silicon my suggestion is to throw it away and move on.

Quoted 1 line

board working with recent u-boot v2019.07.

v2019.07 has long since been released. So what you are talking about would be any future release like v2020.01 as even the v2019.10 merge window long since closed.

Quoted 2 lines

Unfortunaly I get no output on my
serial line.

Quoted 6 lines
Quoted 2 lines

Alpha chips came with different boot ROM requiring completely different SCFW as far as I know.

I have to correct myself. After some investigation I can say that I have the B-Silicium of imx8qm on this board. So should I rename everything from a1 to b1?

Check scfw uart to see whether there is any output from scu uart. Make sure you using and adapt scfw to your board.

Regards,
Peng.

Quoted 4 lines

Best regards,

Oliver

#6 lore raw

cover i.MX8QM ROM 7720 a1 board won't boot

Quoted 27 lines · Peng Fan
Quoted 27 lines

Subject: Re: [PATCH 0/1] i.MX8QM ROM 7720 a1 board won't boot

Quoted 23 lines · Marcel Ziswiler

Hi Oliver

Quoted 2 lines · Oliver Graute

I'am currently working on the following patch to get the imx8qm- rom7720-a1

That version sounds suspiciously like it may be based on initial alpha silicon from NXP which as far as I know is not supported anywhere any more. Not even in downstream.

If it has alpha silicon my suggestion is to throw it away and move on.

Quoted 1 line

board working with recent u-boot v2019.07.

v2019.07 has long since been released. So what you are talking about would be any future release like v2020.01 as even the v2019.10 merge window long since closed.

Quoted 2 lines

Unfortunaly I get no output on my
serial line.

Alpha chips came with different boot ROM requiring completely different SCFW as far as I know.

Quoted 6 lines
Quoted 3 lines

I have to correct myself. After some investigation I can say that I have the B-Silicium of imx8qm on this board. So should I rename everything from a1 to b1?

Check scfw uart to see whether there is any output from scu uart. Make sure you using and adapt scfw to your board.

ok, there is no output on scu uart. So its broken before u-boot launch.

With nxp vendor boostream (scfw + atf + u-boot-imx) I see some output and a little cmd line. So I have to check the stuff before u-boot first.

Best Regards,

Oliver

#7 lore raw

cover i.MX8QM ROM 7720 a1 board won't boot

In reply to Oliver Graute
Quoted 19 lines · Oliver Graute

I'am currently working on the following patch to get the imx8qm-rom7720-a1 board working with recent u-boot v2019.07. Unfortunaly I get no output on my serial line.

I'am not sure if something in my patch is just missing or if my composition of "SCFW + ATF + uboot" which is necessary for this imx8qm board, is not working the right way.

Perhaps somebody can guide me in the right direction to debug this further.

Currently I'am applying the patch and building u-boot this way:

$ export ATF_LOAD_ADDR=0x80000000
$ export BL33_LOAD_ADDR=0x80020000
$ make imx8qm_rom7720_a1_4G_defconfig
$ make flash.bin
$ dd if=u-boot.itb of=flash.bin bs=512 seek=854
$ sudo dd if=flash.bin of=/dev/sd[x] bs=1k seek=32 conv=fsync
Quoted 2 lines

Then I put the SD card into the board and power it on. But no output ony my serial line.

ok I got this working by using the u-boot.bin

$ make u-boot.bin

and put it into the imx-mkimage repo from here:

https://source.codeaurora.org/external/imx/imx-mkimage

to create the full bootstream with scfw + atf + u-boot.

I thought that I could create the full bootsteam directly in u-boot repo with:

Quoted 1 line
$ make flash.bin

as seen for other imx8 boards. Perhaps that is possible too but I don't got it working that way.

U-Boot 2019.07-00001-g5854ff8d0e (Aug 19 2019 - 11:12:49 +0200)

CPU: NXP i.MX8QM RevB A53 at 1200 MHz

Model: Advantech iMX8QM Qseven series
Board: ROM-7720-A1 4GB
Build: SCFW 65afe5f6
Boot:  SD2
DRAM:  3.9 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 2

Loading Environment from MMC... *** Warning - bad CRC, using default environment

In:    serial at 5a060000
Out:   serial at 5a060000
Err:   serial at 5a060000

Net:
Error: ethernet at 5b040000 address not set.
eth-1: ethernet at 5b040000
Error: ethernet at 5b040000 address not set.
Can't find FEC0 clk rate: -22
Could not get PHY for FEC1: addr 1
, eth-1: ethernet at 5b050000
Hit any key to stop autoboot: 0

Best regards,

Oliver