diff options
| author | Simona Toaca <[email protected]> | 2026-04-30 11:33:32 +0300 |
|---|---|---|
| committer | Fabio Estevam <[email protected]> | 2026-05-15 17:31:39 -0300 |
| commit | b37fa572ad07e6bb420df99ac8ff6d0936b15c0e (patch) | |
| tree | 56fe19c6393fb4be02f16b1a658c6f6a424aa345 | |
| parent | 36755f64b34add7b02be8c1845ae089bfc1b934b (diff) | |
board: nxp: imx9{4, 5, 52}_evk: Add qb save option in SPL
Call qb save automatically in the board-specific
spl_board_init(), if SPL_IMX_QB option is enabled.
This makes sure qb_save is called before any image
loading is done by the SPL. This option is also
suitable for the case where U-Boot proper is
missing (Falcon mode).
qb save refers to saving DDR training data to NVM,
so that OEI runs Quickboot flow on next reboot,
skipping full training and achieveing a lower boot
time.
Signed-off-by: Simona Toaca <[email protected]>
| -rw-r--r-- | arch/arm/mach-imx/Kconfig | 8 | ||||
| -rw-r--r-- | board/nxp/imx94_evk/spl.c | 6 | ||||
| -rw-r--r-- | board/nxp/imx952_evk/spl.c | 4 | ||||
| -rw-r--r-- | board/nxp/imx95_evk/spl.c | 6 |
4 files changed, 22 insertions, 2 deletions
diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig index a40baf24631..66142a835ce 100644 --- a/arch/arm/mach-imx/Kconfig +++ b/arch/arm/mach-imx/Kconfig @@ -80,6 +80,14 @@ config IMX_QB memory to non-volatile storage. OEI uses the saved data to run Quickboot flow and skip re-training the DDR PHY. +config SPL_IMX_QB + bool "Run qb save during SPL" + depends on SPL && IMX_QB + help + Automatically save DDR training data (Quickboot data) + to current boot device when needed (when OEI runs Training + flow and saves qb data to volatile memory). + config CMD_IMX_QB bool "Support the 'qb' command" default y diff --git a/board/nxp/imx94_evk/spl.c b/board/nxp/imx94_evk/spl.c index 6eb0fff99f4..739a5f1f559 100644 --- a/board/nxp/imx94_evk/spl.c +++ b/board/nxp/imx94_evk/spl.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0+ /* - * Copyright 2025 NXP + * Copyright 2025-2026 NXP */ #include <hang.h> @@ -14,6 +14,7 @@ #include <asm/arch/sys_proto.h> #include <asm/mach-imx/boot_mode.h> #include <asm/mach-imx/ele_api.h> +#include <asm/mach-imx/qb.h> DECLARE_GLOBAL_DATA_PTR; @@ -44,6 +45,9 @@ void spl_board_init(void) ret = ele_start_rng(); if (ret) printf("Fail to start RNG: %d\n", ret); + + if (IS_ENABLED(CONFIG_SPL_IMX_QB)) + spl_imx_qb_save(); } static void xspi_nor_reset(void) diff --git a/board/nxp/imx952_evk/spl.c b/board/nxp/imx952_evk/spl.c index de9256dc267..615c3b67fb6 100644 --- a/board/nxp/imx952_evk/spl.c +++ b/board/nxp/imx952_evk/spl.c @@ -8,6 +8,7 @@ #include <asm/gpio.h> #include <asm/mach-imx/boot_mode.h> #include <asm/mach-imx/ele_api.h> +#include <asm/mach-imx/qb.h> #include <asm/sections.h> #include <hang.h> #include <init.h> @@ -44,6 +45,9 @@ void spl_board_init(void) ret = ele_start_rng(); if (ret) printf("Fail to start RNG: %d\n", ret); + + if (IS_ENABLED(CONFIG_SPL_IMX_QB)) + spl_imx_qb_save(); } static void xspi_nor_reset(void) diff --git a/board/nxp/imx95_evk/spl.c b/board/nxp/imx95_evk/spl.c index 761a1a4a0f6..2fd69447e1e 100644 --- a/board/nxp/imx95_evk/spl.c +++ b/board/nxp/imx95_evk/spl.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0+ /* - * Copyright 2025 NXP + * Copyright 2025-2026 NXP */ #include <hang.h> @@ -13,6 +13,7 @@ #include <asm/arch/sys_proto.h> #include <asm/mach-imx/boot_mode.h> #include <asm/mach-imx/ele_api.h> +#include <asm/mach-imx/qb.h> DECLARE_GLOBAL_DATA_PTR; @@ -41,6 +42,9 @@ void spl_board_init(void) ret = ele_start_rng(); if (ret) printf("Fail to start RNG: %d\n", ret); + + if (IS_ENABLED(CONFIG_SPL_IMX_QB)) + spl_imx_qb_save(); } void board_init_f(ulong dummy) |
