public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [PATCH v2 0/3] imx93_var_som: Enable AHAB support
@ 2024-02-09 10:30 Mathieu Othacehe
  2024-02-09 10:30 ` [PATCH v2 1/3] imx93: Use a header for imx9_probe_mu declaration Mathieu Othacehe
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Mathieu Othacehe @ 2024-02-09 10:30 UTC (permalink / raw)
  To: Tom Rini, Peng Fan, Shiji Yang, Ye Li, Sébastien Szymanski,
	Fabio Estevam, Simon Glass, Mathieu Othacehe
  Cc: u-boot, Mathieu Othacehe

Hello,

In this v2, I moved imx93_probe_mu to a dedicated header.

Thanks,

Mathieu

Changelog:
v2: Move imx93_probe_mu declaration to a header file

Link to the previous revision:
v1: https://lists.denx.de/pipermail/u-boot/2024-February/545528.html

Mathieu Othacehe (3):
  imx93: Use a header for imx9_probe_mu declaration
  board: imx93_var_som: Probe ELE MU
  configs: imx93_var_som: Enable AHAB support

 arch/arm/include/asm/arch-imx9/mu.h | 13 +++++++++++++
 board/freescale/imx93_evk/spl.c     |  2 +-
 board/phytec/phycore_imx93/spl.c    |  2 +-
 board/variscite/imx93_var_som/spl.c |  5 +++--
 configs/imx93_var_som_defconfig     |  1 +
 5 files changed, 19 insertions(+), 4 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-imx9/mu.h

-- 
2.41.0


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH v2 1/3] imx93: Use a header for imx9_probe_mu declaration
  2024-02-09 10:30 [PATCH v2 0/3] imx93_var_som: Enable AHAB support Mathieu Othacehe
@ 2024-02-09 10:30 ` Mathieu Othacehe
  2024-02-09 22:19   ` Igor Opaniuk
  2024-02-09 10:30 ` [PATCH v2 2/3] board: imx93_var_som: Probe ELE MU Mathieu Othacehe
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 6+ messages in thread
From: Mathieu Othacehe @ 2024-02-09 10:30 UTC (permalink / raw)
  To: Tom Rini, Peng Fan, Shiji Yang, Ye Li, Sébastien Szymanski,
	Fabio Estevam, Simon Glass, Mathieu Othacehe
  Cc: u-boot, Mathieu Othacehe

Put imx9_probe_mu declaration in a new mu.h header file.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
---
 arch/arm/include/asm/arch-imx9/mu.h | 13 +++++++++++++
 board/freescale/imx93_evk/spl.c     |  2 +-
 board/phytec/phycore_imx93/spl.c    |  2 +-
 3 files changed, 15 insertions(+), 2 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-imx9/mu.h

diff --git a/arch/arm/include/asm/arch-imx9/mu.h b/arch/arm/include/asm/arch-imx9/mu.h
new file mode 100644
index 00000000000..b8604992914
--- /dev/null
+++ b/arch/arm/include/asm/arch-imx9/mu.h
@@ -0,0 +1,13 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright (C) 2024 Mathieu Othacehe <m.othacehe@gmail.com>
+ */
+
+#ifndef __ARCH_IMX9_MU_H
+#define __ARCH_IMX9_MU_H
+
+#include <event.h>
+
+int imx9_probe_mu(void *ctx, struct event *event);
+
+#endif
diff --git a/board/freescale/imx93_evk/spl.c b/board/freescale/imx93_evk/spl.c
index be9c24fc0d9..a98ed69db88 100644
--- a/board/freescale/imx93_evk/spl.c
+++ b/board/freescale/imx93_evk/spl.c
@@ -14,6 +14,7 @@
 #include <asm/global_data.h>
 #include <asm/io.h>
 #include <asm/arch/imx93_pins.h>
+#include <asm/arch/mu.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/mach-imx/boot_mode.h>
@@ -91,7 +92,6 @@ int power_init_board(void)
 }
 #endif
 
-extern int imx9_probe_mu(void *ctx, struct event *event);
 void board_init_f(ulong dummy)
 {
 	int ret;
diff --git a/board/phytec/phycore_imx93/spl.c b/board/phytec/phycore_imx93/spl.c
index da4b9e53594..dabc5316f33 100644
--- a/board/phytec/phycore_imx93/spl.c
+++ b/board/phytec/phycore_imx93/spl.c
@@ -7,6 +7,7 @@
 
 #include <asm/arch/clock.h>
 #include <asm/arch/ddr.h>
+#include <asm/arch/mu.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/arch/trdc.h>
 #include <asm/mach-imx/boot_mode.h>
@@ -99,7 +100,6 @@ int power_init_board(void)
 	return 0;
 }
 
-extern int imx9_probe_mu(void *ctx, struct event *event);
 void board_init_f(ulong dummy)
 {
 	int ret;
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH v2 2/3] board: imx93_var_som: Probe ELE MU
  2024-02-09 10:30 [PATCH v2 0/3] imx93_var_som: Enable AHAB support Mathieu Othacehe
  2024-02-09 10:30 ` [PATCH v2 1/3] imx93: Use a header for imx9_probe_mu declaration Mathieu Othacehe
@ 2024-02-09 10:30 ` Mathieu Othacehe
  2024-02-09 10:30 ` [PATCH v2 3/3] configs: imx93_var_som: Enable AHAB support Mathieu Othacehe
  2024-02-12 10:59 ` [PATCH v2 0/3] " Fabio Estevam
  3 siblings, 0 replies; 6+ messages in thread
From: Mathieu Othacehe @ 2024-02-09 10:30 UTC (permalink / raw)
  To: Tom Rini, Peng Fan, Shiji Yang, Ye Li, Sébastien Szymanski,
	Fabio Estevam, Simon Glass, Mathieu Othacehe
  Cc: u-boot, Mathieu Othacehe

Probing the MU is needed to prevent this error in the SPL:

ele dev is not initialized
Authenticate container hdr failed, return -19, resp 0x0
IND = INVALID

ele dev is not initialized
Error: release container failed, resp 0x0!
IND = INVALID

SPL: failed to boot from all boot devices

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
---
 board/variscite/imx93_var_som/spl.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/board/variscite/imx93_var_som/spl.c b/board/variscite/imx93_var_som/spl.c
index 502e599b91a..e6db4eb562b 100644
--- a/board/variscite/imx93_var_som/spl.c
+++ b/board/variscite/imx93_var_som/spl.c
@@ -13,6 +13,7 @@
 #include <asm/global_data.h>
 #include <asm/io.h>
 #include <asm/arch/imx93_pins.h>
+#include <asm/arch/mu.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/mach-imx/boot_mode.h>
@@ -114,9 +115,9 @@ void board_init_f(ulong dummy)
 
 	preloader_console_init();
 
-	ret = arch_cpu_init();
+	ret = imx9_probe_mu(NULL, NULL);
 	if (ret) {
-		printf("Fail to init Sentinel API\n");
+		printf("Fail to init ELE API\n");
 	} else {
 		printf("SOC: 0x%x\n", gd->arch.soc_rev);
 		printf("LC: 0x%x\n", gd->arch.lifecycle);
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH v2 3/3] configs: imx93_var_som: Enable AHAB support
  2024-02-09 10:30 [PATCH v2 0/3] imx93_var_som: Enable AHAB support Mathieu Othacehe
  2024-02-09 10:30 ` [PATCH v2 1/3] imx93: Use a header for imx9_probe_mu declaration Mathieu Othacehe
  2024-02-09 10:30 ` [PATCH v2 2/3] board: imx93_var_som: Probe ELE MU Mathieu Othacehe
@ 2024-02-09 10:30 ` Mathieu Othacehe
  2024-02-12 10:59 ` [PATCH v2 0/3] " Fabio Estevam
  3 siblings, 0 replies; 6+ messages in thread
From: Mathieu Othacehe @ 2024-02-09 10:30 UTC (permalink / raw)
  To: Tom Rini, Peng Fan, Shiji Yang, Ye Li, Sébastien Szymanski,
	Fabio Estevam, Simon Glass, Mathieu Othacehe
  Cc: u-boot, Mathieu Othacehe

Enable AHAB support in the imx93_var_som configuration.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
---
 configs/imx93_var_som_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/configs/imx93_var_som_defconfig b/configs/imx93_var_som_defconfig
index cc0c5a79bc1..14922f2a3e2 100644
--- a/configs/imx93_var_som_defconfig
+++ b/configs/imx93_var_som_defconfig
@@ -12,6 +12,7 @@ CONFIG_IMX_CONFIG="arch/arm/mach-imx/imx9/imximage.cfg"
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="imx93-var-som-symphony"
 CONFIG_SPL_TEXT_BASE=0x2049A000
+CONFIG_AHAB_BOOT=y
 CONFIG_TARGET_IMX93_VAR_SOM=y
 CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SPL_SERIAL=y
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v2 1/3] imx93: Use a header for imx9_probe_mu declaration
  2024-02-09 10:30 ` [PATCH v2 1/3] imx93: Use a header for imx9_probe_mu declaration Mathieu Othacehe
@ 2024-02-09 22:19   ` Igor Opaniuk
  0 siblings, 0 replies; 6+ messages in thread
From: Igor Opaniuk @ 2024-02-09 22:19 UTC (permalink / raw)
  To: Mathieu Othacehe
  Cc: Tom Rini, Peng Fan, Shiji Yang, Ye Li, Sébastien Szymanski,
	Fabio Estevam, Simon Glass, Mathieu Othacehe, u-boot

On Fri, Feb 9, 2024 at 1:05 PM Mathieu Othacehe <othacehe@gnu.org> wrote:
>
> Put imx9_probe_mu declaration in a new mu.h header file.
>
> Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
> ---
>  arch/arm/include/asm/arch-imx9/mu.h | 13 +++++++++++++
>  board/freescale/imx93_evk/spl.c     |  2 +-
>  board/phytec/phycore_imx93/spl.c    |  2 +-
>  3 files changed, 15 insertions(+), 2 deletions(-)
>  create mode 100644 arch/arm/include/asm/arch-imx9/mu.h
>
> diff --git a/arch/arm/include/asm/arch-imx9/mu.h b/arch/arm/include/asm/arch-imx9/mu.h
> new file mode 100644
> index 00000000000..b8604992914
> --- /dev/null
> +++ b/arch/arm/include/asm/arch-imx9/mu.h
> @@ -0,0 +1,13 @@
> +/* SPDX-License-Identifier: GPL-2.0+ */
> +/*
> + * Copyright (C) 2024 Mathieu Othacehe <m.othacehe@gmail.com>
> + */
> +
> +#ifndef __ARCH_IMX9_MU_H
> +#define __ARCH_IMX9_MU_H
> +
> +#include <event.h>
> +
> +int imx9_probe_mu(void *ctx, struct event *event);
> +
> +#endif
> diff --git a/board/freescale/imx93_evk/spl.c b/board/freescale/imx93_evk/spl.c
> index be9c24fc0d9..a98ed69db88 100644
> --- a/board/freescale/imx93_evk/spl.c
> +++ b/board/freescale/imx93_evk/spl.c
> @@ -14,6 +14,7 @@
>  #include <asm/global_data.h>
>  #include <asm/io.h>
>  #include <asm/arch/imx93_pins.h>
> +#include <asm/arch/mu.h>
>  #include <asm/arch/clock.h>
>  #include <asm/arch/sys_proto.h>
>  #include <asm/mach-imx/boot_mode.h>
> @@ -91,7 +92,6 @@ int power_init_board(void)
>  }
>  #endif
>
> -extern int imx9_probe_mu(void *ctx, struct event *event);
>  void board_init_f(ulong dummy)
>  {
>         int ret;
> diff --git a/board/phytec/phycore_imx93/spl.c b/board/phytec/phycore_imx93/spl.c
> index da4b9e53594..dabc5316f33 100644
> --- a/board/phytec/phycore_imx93/spl.c
> +++ b/board/phytec/phycore_imx93/spl.c
> @@ -7,6 +7,7 @@
>
>  #include <asm/arch/clock.h>
>  #include <asm/arch/ddr.h>
> +#include <asm/arch/mu.h>
>  #include <asm/arch/sys_proto.h>
>  #include <asm/arch/trdc.h>
>  #include <asm/mach-imx/boot_mode.h>
> @@ -99,7 +100,6 @@ int power_init_board(void)
>         return 0;
>  }
>
> -extern int imx9_probe_mu(void *ctx, struct event *event);
>  void board_init_f(ulong dummy)
>  {
>         int ret;
> --
> 2.41.0
>

Reviewed-by: Igor Opaniuk <igor.opaniuk@foundries.io>

-- 
Best regards - Freundliche Grüsse - Meilleures salutations

Igor Opaniuk
Senior Software Engineer, Embedded & Security
E: igor.opaniuk@foundries.io
W: www.foundries.io

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v2 0/3] imx93_var_som: Enable AHAB support
  2024-02-09 10:30 [PATCH v2 0/3] imx93_var_som: Enable AHAB support Mathieu Othacehe
                   ` (2 preceding siblings ...)
  2024-02-09 10:30 ` [PATCH v2 3/3] configs: imx93_var_som: Enable AHAB support Mathieu Othacehe
@ 2024-02-12 10:59 ` Fabio Estevam
  3 siblings, 0 replies; 6+ messages in thread
From: Fabio Estevam @ 2024-02-12 10:59 UTC (permalink / raw)
  To: Mathieu Othacehe
  Cc: Tom Rini, Peng Fan, Shiji Yang, Ye Li, Sébastien Szymanski,
	Simon Glass, Mathieu Othacehe, u-boot

On Fri, Feb 9, 2024 at 7:30 AM Mathieu Othacehe <othacehe@gnu.org> wrote:
>
> Hello,
>
> In this v2, I moved imx93_probe_mu to a dedicated header.

Applied all, thanks.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-02-12 10:59 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-09 10:30 [PATCH v2 0/3] imx93_var_som: Enable AHAB support Mathieu Othacehe
2024-02-09 10:30 ` [PATCH v2 1/3] imx93: Use a header for imx9_probe_mu declaration Mathieu Othacehe
2024-02-09 22:19   ` Igor Opaniuk
2024-02-09 10:30 ` [PATCH v2 2/3] board: imx93_var_som: Probe ELE MU Mathieu Othacehe
2024-02-09 10:30 ` [PATCH v2 3/3] configs: imx93_var_som: Enable AHAB support Mathieu Othacehe
2024-02-12 10:59 ` [PATCH v2 0/3] " Fabio Estevam

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox