From 453def7956c864818b6d6a1a44b2b267df3a44fc Mon Sep 17 00:00:00 2001 From: Otavio Salvador Date: Sat, 23 Jul 2022 13:52:57 -0300 Subject: imx-atf: allow setting the UART used during boot A new `ATF_BOOT_UART_BASE` variable can be used in machine to set the UART aimed for use during the boot, without the need of changing the source code. Signed-off-by: Otavio Salvador --- recipes-bsp/imx-atf/imx-atf_2.6.bb | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'recipes-bsp') diff --git a/recipes-bsp/imx-atf/imx-atf_2.6.bb b/recipes-bsp/imx-atf/imx-atf_2.6.bb index 95258247e..194ef935a 100644 --- a/recipes-bsp/imx-atf/imx-atf_2.6.bb +++ b/recipes-bsp/imx-atf/imx-atf_2.6.bb @@ -18,7 +18,11 @@ S = "${WORKDIR}/git" inherit deploy -ATF_PLATFORM ??= "INVALID" +ATF_PLATFORM ??= "INVALID" + +# FIXME: We should return INVALID here but currently only i.MX8M has support to override the UART +# base address in source code. +ATF_BOOT_UART_BASE ?= "" EXTRA_OEMAKE += " \ CROSS_COMPILE="${TARGET_PREFIX}" \ @@ -48,6 +52,9 @@ EXTRA_OEMAKE += 'LD="${@remove_options_tail(d.getVar('LD'))}"' EXTRA_OEMAKE += 'CC="${@remove_options_tail(d.getVar('CC'))}"' +# Set the UART to use during the boot. +EXTRA_OEMAKE += 'IMX_BOOT_UART_BASE=${ATF_BOOT_UART_BASE}' + do_configure[noexec] = "1" do_compile() { -- cgit v1.2.3-54-g00ecf