From: Chali Anis <chalian...@gmail.com> add the ability to be booted from Arm Trusted Firmware for qemu aarch64, to do so we need to skip NOR flash partition setup. U-boot launched as BL33 from TF-A is supported and Tested on arm64 with qemu-system-aarch64 and the qemu ARM64 support ARCH_SUPPORT_TFABOOT.
Signed-off-by: Chali Anis <chalian...@gmail.com> --- arch/arm/mach-qemu/Kconfig | 1 + board/emulation/common/qemu_mtdparts.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/arch/arm/mach-qemu/Kconfig b/arch/arm/mach-qemu/Kconfig index 9c06c6a3a5ce..316dde5145c0 100644 --- a/arch/arm/mach-qemu/Kconfig +++ b/arch/arm/mach-qemu/Kconfig @@ -18,6 +18,7 @@ config TARGET_QEMU_ARM_64BIT bool "ARMv8, 64bit" select ARM64 select BOARD_LATE_INIT + select ARCH_SUPPORT_TFABOOT config TARGET_QEMU_ARM_SBSA bool "SBSA Reference" diff --git a/board/emulation/common/qemu_mtdparts.c b/board/emulation/common/qemu_mtdparts.c index c1501276789c..c3863d3b0479 100644 --- a/board/emulation/common/qemu_mtdparts.c +++ b/board/emulation/common/qemu_mtdparts.c @@ -59,6 +59,7 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts) debug("mtd device = %s\n", dev->name); } +#ifndef CONFIG_TFABOOT mtd = get_mtd_device_nm("nor0"); if (!IS_ERR_OR_NULL(mtd)) { mtd_partition = CONFIG_MTDPARTS_NOR0; @@ -72,6 +73,7 @@ void board_mtdparts_default(const char **mtdids, const char **mtdparts) board_get_mtdparts("nor1", mtd_partition, ids, parts); put_mtd_device(mtd); } +#endif } mtd_initialized = true; -- 2.34.1