Skip to contentSkip to conversation

imx: imx8qm: imx8qm_mek switch to binman

PATCH Superseded Oliver Graute 3 participants 3 messages Oct 26, 2022 – Oct 27, 2022

Subsystems (3)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 imx: imx8qm: imx8qm_mek switch to binman

---
 arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi | 2 ++
 arch/arm/mach-imx/imx8/Kconfig          | 1 +
 board/freescale/imx8qm_mek/README       | 2 +-
 board/freescale/imx8qm_mek/imximage.cfg | 2 +-
 configs/imx8qm_mek_defconfig            | 2 ++
 5 files changed, 7 insertions(+), 2 deletions(-)
arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi +2 -0
index a95209e141..eefdccf992 100644
@@ -3,6 +3,8 @@
  * Copyright 2018, 2021 NXP
  */
 
+#include "imx8qm-u-boot.dtsi"
+
 &{/imx8qm-pm} {
 
 	u-boot,dm-spl;
arch/arm/mach-imx/imx8/Kconfig +1 -0
index 23a7fcf361..4ccbabf506 100644
@@ -68,6 +68,7 @@ config TARGET_GIEDI
 
 config TARGET_IMX8QM_MEK
 	bool "Support i.MX8QM MEK board"
+	select BINMAN
 	select BOARD_LATE_INIT
 	select IMX8QM
 	select FSL_CAAM
board/freescale/imx8qm_mek/README +1 -1
index 570ed7e210..b1a4c6cc82 100644
@@ -40,7 +40,7 @@ And copy the following firmwares to U-Boot folder:
 Build U-Boot
 ============
 $ make imx8qm_mek_defconfig
-$ make flash.bin
+$ make
 
 Flash the binary into the SD card
 =================================
board/freescale/imx8qm_mek/imximage.cfg +1 -1
index 71612678c9..46ca3bf817 100644
@@ -5,7 +5,7 @@
 
 
 /* Boot from SD, sector size 0x400 */
-BOOT_FROM SD 0x400
+BOOT_FROM	sd
 /* SoC type IMX8QM */
 SOC_TYPE IMX8QM
 /* Append seco container image */
configs/imx8qm_mek_defconfig +2 -0
index b973b809be..25b51cf1ec 100644
@@ -23,6 +23,8 @@ CONFIG_SYS_LOAD_ADDR=0x80280000
 CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x80200000
 CONFIG_REMAKE_ELF=y
+CONFIG_FIT=y
+CONFIG_FIT_EXTERNAL_OFFSET=0x3000
 CONFIG_OF_BOARD_SETUP=y
 CONFIG_OF_SYSTEM_SETUP=y
 CONFIG_BOOTDELAY=3
Signature · 1 line
2.17.1
#1 lore raw
Quoted 14 lines · Oliver Graute
---
  arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi | 2 ++
  arch/arm/mach-imx/imx8/Kconfig          | 1 +
  board/freescale/imx8qm_mek/README       | 2 +-
  board/freescale/imx8qm_mek/imximage.cfg | 2 +-
  configs/imx8qm_mek_defconfig            | 2 ++
  5 files changed, 7 insertions(+), 2 deletions(-)
arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi +0 -0
index a95209e141..eefdccf992 100644

arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi line 7

Quoted 5 lines
arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi +2 -0
@@ -3,6 +3,8 @@
   * Copyright 2018, 2021 NXP
   */
 
+#include "imx8qm-u-boot.dtsi"
+

I think the build system would automatically include this. Please correct if I am wrong.

Quoted 33 lines
arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi +0 -0
  &{/imx8qm-pm} {
 
  	u-boot,dm-spl;
arch/arm/mach-imx/imx8/Kconfig +1 -0
index 23a7fcf361..4ccbabf506 100644
@@ -68,6 +68,7 @@ config TARGET_GIEDI
 
  config TARGET_IMX8QM_MEK
  	bool "Support i.MX8QM MEK board"
+	select BINMAN
  	select BOARD_LATE_INIT
  	select IMX8QM
  	select FSL_CAAM
board/freescale/imx8qm_mek/README +1 -1
index 570ed7e210..b1a4c6cc82 100644
@@ -40,7 +40,7 @@ And copy the following firmwares to U-Boot folder:
  Build U-Boot
  ============
  $ make imx8qm_mek_defconfig
-$ make flash.bin
+$ make
 
  Flash the binary into the SD card
  =================================
board/freescale/imx8qm_mek/imximage.cfg +0 -0
index 71612678c9..46ca3bf817 100644

board/freescale/imx8qm_mek/imximage.cfg line 8

Quoted 5 lines
board/freescale/imx8qm_mek/imximage.cfg +1 -1
@@ -5,7 +5,7 @@
 
 
  /* Boot from SD, sector size 0x400 */
-BOOT_FROM SD 0x400
+BOOT_FROM	sd

Why update this?

Quoted 8 lines
board/freescale/imx8qm_mek/imximage.cfg +0 -0
  /* SoC type IMX8QM */
  SOC_TYPE IMX8QM
  /* Append seco container image */
configs/imx8qm_mek_defconfig +0 -0
index b973b809be..25b51cf1ec 100644

configs/imx8qm_mek_defconfig CONFIG_SYS_LOAD_ADDR=0x80280000 · line 30

Quoted 8 lines
configs/imx8qm_mek_defconfig +2 -0
@@ -23,6 +23,8 @@ CONFIG_SYS_LOAD_ADDR=0x80280000
  CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
  CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x80200000
  CONFIG_REMAKE_ELF=y
+CONFIG_FIT=y
+CONFIG_FIT_EXTERNAL_OFFSET=0x3000
  CONFIG_OF_BOARD_SETUP=y
  CONFIG_OF_SYSTEM_SETUP=y
  CONFIG_BOOTDELAY=3

Regards,
Peng.

#2 lore raw
Quoted 12 lines · Peng Fan
Quoted 9 lines · Oliver Graute
---
  arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi | 2 ++
  arch/arm/mach-imx/imx8/Kconfig          | 1 +
  board/freescale/imx8qm_mek/README       | 2 +-
  board/freescale/imx8qm_mek/imximage.cfg | 2 +-
  configs/imx8qm_mek_defconfig            | 2 ++
  5 files changed, 7 insertions(+), 2 deletions(-)
Quoted 12 lines

arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi line 6

Quoted 9 lines
arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi +2 -0
index a95209e141..eefdccf992 100644
@@ -3,6 +3,8 @@
   * Copyright 2018, 2021 NXP
   */
+#include "imx8qm-u-boot.dtsi"
+

I think the build system would automatically include this. Please correct if I am wrong.

That's not the case if I remove the include I run into following error:

make[1]: Für das Ziel „SPL“ ist nichts zu tun.
BINMAN all
binman: Device tree 'u-boot.dtb' does not have a 'binman' node Makefile:1109: recipe for target 'all' failed
make: *** [all] Error 1

Quoted 28 lines
Quoted 28 lines
arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi +0 -0
  &{/imx8qm-pm} {
  	u-boot,dm-spl;
arch/arm/mach-imx/imx8/Kconfig +1 -0
index 23a7fcf361..4ccbabf506 100644
@@ -68,6 +68,7 @@ config TARGET_GIEDI
  config TARGET_IMX8QM_MEK
  	bool "Support i.MX8QM MEK board"
+	select BINMAN
  	select BOARD_LATE_INIT
  	select IMX8QM
  	select FSL_CAAM
board/freescale/imx8qm_mek/README +1 -1
index 570ed7e210..b1a4c6cc82 100644
@@ -40,7 +40,7 @@ And copy the following firmwares to U-Boot folder:
  Build U-Boot
  ============
  $ make imx8qm_mek_defconfig
-$ make flash.bin
+$ make
  Flash the binary into the SD card
  =================================
board/freescale/imx8qm_mek/imximage.cfg +0 -0
index 71612678c9..46ca3bf817 100644
Quoted 8 lines

board/freescale/imx8qm_mek/imximage.cfg line 6

Quoted 6 lines
board/freescale/imx8qm_mek/imximage.cfg +1 -1
@@ -5,7 +5,7 @@
  /* Boot from SD, sector size 0x400 */
-BOOT_FROM SD 0x400
+BOOT_FROM	sd

Why update this?

you are right its unneccessary, will fix it in v2

Quoted 12 lines
Quoted 12 lines
board/freescale/imx8qm_mek/imximage.cfg +0 -0
  /* SoC type IMX8QM */
  SOC_TYPE IMX8QM
  /* Append seco container image */
configs/imx8qm_mek_defconfig +0 -0
index b973b809be..25b51cf1ec 100644
@@ -23,6 +23,8 @@ CONFIG_SYS_LOAD_ADDR=0x80280000
  CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
  CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x80200000
  CONFIG_REMAKE_ELF=y
Quoted 8 lines

configs/imx8qm_mek_defconfig CONFIG_SYS_LOAD_ADDR=0x80280000 · line 30

Quoted 5 lines
configs/imx8qm_mek_defconfig +2 -0
+CONFIG_FIT=y
+CONFIG_FIT_EXTERNAL_OFFSET=0x3000
  CONFIG_OF_BOARD_SETUP=y
  CONFIG_OF_SYSTEM_SETUP=y
  CONFIG_BOOTDELAY=3

Regards,
Peng.

Best Regards,

Oliver