The Allwinner V3s (suniv) BROM returns SUNIV_BOOTED_FROM_NAND when successfully booting from an attached SPI NAND flash. Currently, U-Boot lacks the mapping and treats this as an invalid boot source.
Map this to SUNXI_BOOTED_FROM_SPI to ensure the boot environment and device are correctly identified in U-Boot proper. Note that this patch only corrects the boot source mapping; specific SPL SPI NAND loading implementations are handled separately. Tested-on: Allwinner V3s, SPI NAND boot. Signed-off-by: Zunyi Hu <[email protected]> --- arch/arm/mach-sunxi/board.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/arm/mach-sunxi/board.c b/arch/arm/mach-sunxi/board.c index 432b1c10f92..7f85bd0c7d3 100644 --- a/arch/arm/mach-sunxi/board.c +++ b/arch/arm/mach-sunxi/board.c @@ -238,9 +238,8 @@ static int suniv_get_boot_source(void) return SUNXI_BOOTED_FROM_SPI; case SUNIV_BOOTED_FROM_MMC1: return SUNXI_BOOTED_FROM_MMC2; - /* SPI NAND is not supported yet. */ case SUNIV_BOOTED_FROM_NAND: - return SUNXI_INVALID_BOOT_SOURCE; + return SUNXI_BOOTED_FROM_SPI; } /* If we get here something went wrong try to boot from FEL.*/ printf("Unknown boot source from BROM: 0x%x\n", brom_call); -- 2.17.1

