From a1e56cf6d430d78db3a4dc08a422311145e32315 Mon Sep 17 00:00:00 2001 From: Nikita Kiryanov Date: Sun, 8 Nov 2015 17:11:54 +0200 Subject: spl: mmc: add support for BOOT_DEVICE_MMC2 Currently the mmc device that SPL looks at is always mmc0, regardless of the BOOT_DEVICE_MMCx value. This forces some boards to implement hacks in order to boot from other mmc devices. Make SPL take into account the correct mmc device. Signed-off-by: Nikita Kiryanov Reviewed-by: Tom Rini --- arch/arm/cpu/armv7/sunxi/board.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'arch/arm/cpu/armv7/sunxi/board.c') diff --git a/arch/arm/cpu/armv7/sunxi/board.c b/arch/arm/cpu/armv7/sunxi/board.c index 9b5c46b354..794b829e1c 100644 --- a/arch/arm/cpu/armv7/sunxi/board.c +++ b/arch/arm/cpu/armv7/sunxi/board.c @@ -173,16 +173,8 @@ u32 spl_boot_device(void) #ifdef CONFIG_MMC if (CONFIG_MMC_SUNXI_SLOT_EXTRA == 2) { mmc1 = find_mmc_device(1); - if (sunxi_mmc_has_egon_boot_signature(mmc1)) { - /* - * spl_mmc.c: spl_mmc_load_image() is hard-coded to - * use find_mmc_device(0), no matter what we - * return. Swap mmc0 and mmc2 to make this work. - */ - mmc0->block_dev.dev = 1; - mmc1->block_dev.dev = 0; + if (sunxi_mmc_has_egon_boot_signature(mmc1)) return BOOT_DEVICE_MMC2; - } } #endif -- cgit v1.2.1