diff mbox series

imx: imx-hab: Select SPL_DRIVERS_MISC in the SPL case

Message ID 20231211134617.457471-1-festevam@gmail.com
State Accepted
Commit 04bb59b4083147ad164594048258961c30089a64
Delegated to: Fabio Estevam
Headers show
Series imx: imx-hab: Select SPL_DRIVERS_MISC in the SPL case | expand

Commit Message

Fabio Estevam Dec. 11, 2023, 1:46 p.m. UTC
From: Fabio Estevam <festevam@denx.de>

Selecting CONFIG_IMX_HAB=y on a SPL target, such as apalis_imx6_defconfig,
for example, leads to the following build error:

/usr/bin/arm-linux-gnueabihf-ld.bfd: arch/arm/mach-imx/hab.o: in function `imx_hab_is_enabled':
arch/arm/mach-imx/hab.c:879: undefined reference to `fuse_read'

fuse_read() comes from SPL_MXC_OCOTP, which depends on SPL_DRIVERS_MISC,
since commit 251a3053b1e6 ("misc: imx: remove DM dependency for ocotp
driver in SPL").

Select SPL_DRIVERS_MISC in the SPL case to fix this build issue.

Reported-by: Lisandro Pérez Meyer <lpmeyer@ics.com>
Signed-off-by: Fabio Estevam <festevam@denx.de>
---
 arch/arm/mach-imx/Kconfig | 1 +
 1 file changed, 1 insertion(+)

Comments

Lisandro Pérez Meyer Dec. 11, 2023, 2:45 p.m. UTC | #1
On Mon, Dec 11, 2023 at 10:46 AM Fabio Estevam <festevam@gmail.com> wrote:
>
> From: Fabio Estevam <festevam@denx.de>
>
> Selecting CONFIG_IMX_HAB=y on a SPL target, such as apalis_imx6_defconfig,
> for example, leads to the following build error:
>
> /usr/bin/arm-linux-gnueabihf-ld.bfd: arch/arm/mach-imx/hab.o: in function `imx_hab_is_enabled':
> arch/arm/mach-imx/hab.c:879: undefined reference to `fuse_read'
>
> fuse_read() comes from SPL_MXC_OCOTP, which depends on SPL_DRIVERS_MISC,
> since commit 251a3053b1e6 ("misc: imx: remove DM dependency for ocotp
> driver in SPL").
>
> Select SPL_DRIVERS_MISC in the SPL case to fix this build issue.
>
> Reported-by: Lisandro Pérez Meyer <lpmeyer@ics.com>
> Signed-off-by: Fabio Estevam <festevam@denx.de>
> ---
>  arch/arm/mach-imx/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
> index abd48d42583a..c34bc25c0bfb 100644
> --- a/arch/arm/mach-imx/Kconfig
> +++ b/arch/arm/mach-imx/Kconfig
> @@ -54,6 +54,7 @@ config IMX_HAB
>         bool "Support i.MX HAB features"
>         depends on ARCH_MX7 || ARCH_MX6 || ARCH_MX5 || ARCH_IMX8M || ARCH_MX7ULP
>         select FSL_CAAM if HAS_CAAM
> +       select SPL_DRIVERS_MISC if SPL
>         imply CMD_DEKBLOB if HAS_CAAM
>         help
>           This option enables the support for secure boot (HAB).
> --
> 2.34.1

I actually tested this, so, should I reply with Reviewed-By?
Fabio Estevam Dec. 11, 2023, 2:48 p.m. UTC | #2
Hi Lisandro,

On 11/12/2023 11:45, Lisandro Pérez Meyer wrote:

> I actually tested this, so, should I reply with Reviewed-By?

Feel free to reply with your Tested-by tag.

Thanks
Lisandro Pérez Meyer Dec. 11, 2023, 5:48 p.m. UTC | #3
On Mon, Dec 11, 2023 at 10:46 AM Fabio Estevam <festevam@gmail.com> wrote:
>
> From: Fabio Estevam <festevam@denx.de>
>
> Selecting CONFIG_IMX_HAB=y on a SPL target, such as apalis_imx6_defconfig,
> for example, leads to the following build error:
>
> /usr/bin/arm-linux-gnueabihf-ld.bfd: arch/arm/mach-imx/hab.o: in function `imx_hab_is_enabled':
> arch/arm/mach-imx/hab.c:879: undefined reference to `fuse_read'
>
> fuse_read() comes from SPL_MXC_OCOTP, which depends on SPL_DRIVERS_MISC,
> since commit 251a3053b1e6 ("misc: imx: remove DM dependency for ocotp
> driver in SPL").
>
> Select SPL_DRIVERS_MISC in the SPL case to fix this build issue.
>
> Reported-by: Lisandro Pérez Meyer <lpmeyer@ics.com>
> Signed-off-by: Fabio Estevam <festevam@denx.de>
> ---
>  arch/arm/mach-imx/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
> index abd48d42583a..c34bc25c0bfb 100644
> --- a/arch/arm/mach-imx/Kconfig
> +++ b/arch/arm/mach-imx/Kconfig
> @@ -54,6 +54,7 @@ config IMX_HAB
>         bool "Support i.MX HAB features"
>         depends on ARCH_MX7 || ARCH_MX6 || ARCH_MX5 || ARCH_IMX8M || ARCH_MX7ULP
>         select FSL_CAAM if HAS_CAAM
> +       select SPL_DRIVERS_MISC if SPL
>         imply CMD_DEKBLOB if HAS_CAAM
>         help
>           This option enables the support for secure boot (HAB).
> --
> 2.34.1
>

Tested-by: Lisandro Pérez Meyer <lpmeyer@ics.com>
Fabio Estevam Dec. 14, 2023, 2:02 a.m. UTC | #4
On Mon, Dec 11, 2023 at 10:46 AM Fabio Estevam <festevam@gmail.com> wrote:
>
> From: Fabio Estevam <festevam@denx.de>
>
> Selecting CONFIG_IMX_HAB=y on a SPL target, such as apalis_imx6_defconfig,
> for example, leads to the following build error:
>
> /usr/bin/arm-linux-gnueabihf-ld.bfd: arch/arm/mach-imx/hab.o: in function `imx_hab_is_enabled':
> arch/arm/mach-imx/hab.c:879: undefined reference to `fuse_read'
>
> fuse_read() comes from SPL_MXC_OCOTP, which depends on SPL_DRIVERS_MISC,
> since commit 251a3053b1e6 ("misc: imx: remove DM dependency for ocotp
> driver in SPL").
>
> Select SPL_DRIVERS_MISC in the SPL case to fix this build issue.
>
> Reported-by: Lisandro Pérez Meyer <lpmeyer@ics.com>
> Signed-off-by: Fabio Estevam <festevam@denx.de>

Applied to u-boot-imx next, thanks.
diff mbox series

Patch

diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
index abd48d42583a..c34bc25c0bfb 100644
--- a/arch/arm/mach-imx/Kconfig
+++ b/arch/arm/mach-imx/Kconfig
@@ -54,6 +54,7 @@  config IMX_HAB
 	bool "Support i.MX HAB features"
 	depends on ARCH_MX7 || ARCH_MX6 || ARCH_MX5 || ARCH_IMX8M || ARCH_MX7ULP
 	select FSL_CAAM if HAS_CAAM
+	select SPL_DRIVERS_MISC if SPL
 	imply CMD_DEKBLOB if HAS_CAAM
 	help
 	  This option enables the support for secure boot (HAB).