diff options
| author | Mathieu Dubois-Briand <[email protected]> | 2025-09-15 14:57:02 +0200 |
|---|---|---|
| committer | Fabio Estevam <[email protected]> | 2025-09-20 17:46:40 -0300 |
| commit | 8918b60e33157dd6abaaf11ea24437da133eed0a (patch) | |
| tree | 96672fd856d2991e1c7c626602a7310c0237607a /board | |
| parent | 9f90e39d1cc458e2955c1edbe8a018c0c6c08b32 (diff) | |
imx93_frdm: Add support for flashing board with UUU
Allow to flash a board using NXP UUU utility:
- Enable fastboot support on USB.
- Add fastboot partition aliases with names used by UUU. Also add extra
environment variables used by UUU.
- Set 'dofastboot' environment variable based on boot device
configuration, allowing to automatically enter fastboot when booting
from USB.
Signed-off-by: Mathieu Dubois-Briand <[email protected]>
Diffstat (limited to 'board')
| -rw-r--r-- | board/freescale/imx93_frdm/imx93_frdm.c | 6 | ||||
| -rw-r--r-- | board/freescale/imx93_frdm/imx93_frdm.env | 8 |
2 files changed, 14 insertions, 0 deletions
diff --git a/board/freescale/imx93_frdm/imx93_frdm.c b/board/freescale/imx93_frdm/imx93_frdm.c index c74fd85712f..c436ac6aa47 100644 --- a/board/freescale/imx93_frdm/imx93_frdm.c +++ b/board/freescale/imx93_frdm/imx93_frdm.c @@ -10,6 +10,7 @@ #include <asm/arch/sys_proto.h> #include <asm/arch-imx9/imx93_pins.h> #include <asm/arch/clock.h> +#include <asm/mach-imx/boot_mode.h> #include <dm/device.h> #include <dm/uclass.h> @@ -55,5 +56,10 @@ int board_late_init(void) env_set("board_rev", "iMX93"); } + if (get_boot_device() == USB_BOOT) { + printf("USB boot detected. Will enter fasboot mode\n"); + env_set_ulong("dofastboot", 1); + } + return 0; } diff --git a/board/freescale/imx93_frdm/imx93_frdm.env b/board/freescale/imx93_frdm/imx93_frdm.env index 528a953c8df..111f38ed72a 100644 --- a/board/freescale/imx93_frdm/imx93_frdm.env +++ b/board/freescale/imx93_frdm/imx93_frdm.env @@ -19,8 +19,16 @@ kernel_addr_r=CONFIG_SYS_LOAD_ADDR loadimage=load mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image} loadfdt=load mmc ${mmcdev}:${mmcpart} ${fdt_addr_r} ${fdtfile} boot_os=booti ${loadaddr} - ${fdt_addr_r} +fastboot_partition_alias_all=0:0 +fastboot_partition_alias_bootloader=0.1 +emmc_dev=0 +sd_dev=1 +dofastboot=0 bsp_bootcmd= + if test ${dofastboot} = 1; then + fastboot 0; + fi; echo Running BSP bootcmd ...; mmc dev ${mmcdev}; run mmcargs; |
