summaryrefslogtreecommitdiff
path: root/arch/arm/cpu
diff options
context:
space:
mode:
authorNikita Kiryanov <nikita@compulab.co.il>2015-11-08 17:11:54 +0200
committerTom Rini <trini@konsulko.com>2015-11-18 14:50:05 -0500
commita1e56cf6d430d78db3a4dc08a422311145e32315 (patch)
treefbb5d3da1633eda25681e83e0cd6e4ec04fd785f /arch/arm/cpu
parent7b9e980e870294ab36f5b0f36abcb034a4955d29 (diff)
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 <nikita@compulab.co.il> Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'arch/arm/cpu')
-rw-r--r--arch/arm/cpu/armv7/sunxi/board.c10
1 files changed, 1 insertions, 9 deletions
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