From: Anatolij Gustschin <agust@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] spl: mmc: make eMMC HW boot partition configuration optional
Date: Fri, 18 Oct 2019 21:38:33 +0200 [thread overview]
Message-ID: <20191018193833.8481-1-agust@denx.de> (raw)
Loading U-Boot on i.MX8QXP MEK board is broken since recent changes
in spl_mmc:
U-Boot SPL 2019.10-00162-gff5bd397e4 (Oct 18 2019 - 15:50:45 +0200)
Normal Boot
WDT: Not found!
Trying to boot from MMC2_2
Load image from MMC/SD 0x46400
spl: mmc partition switch failed
SPL: failed to boot from all boot devices
### ERROR ### Please RESET the board ###
The newly added CONFIG_SYS_MMCSD_RAW_MODE_EMMC_BOOT_PARTITION option
is selected automatically and overrides the EXT_CSC_PART_CONFIG
configurations with default value, always selecting the eMMC boot
partition 1. Boards which place U-Boot image in other partitions
became not bootable.
Fix this by making the eMMC HW boot partition selection optional.
Fixes: 17241ea0543a (spl: mmc: Add option to set eMMC HW boot partition)
Signed-off-by: Anatolij Gustschin <agust@denx.de>
---
Hi Tom,
Many other boards (using CONFIG_SUPPORT_EMMC_BOOT) are affected, too.
So, this (or other suitable fix) should be applied ASAP.
Thanks,
Anatolij
common/spl/Kconfig | 28 ++++++++++++++++++++++------
1 file changed, 22 insertions(+), 6 deletions(-)
diff --git a/common/spl/Kconfig b/common/spl/Kconfig
index 562eafe2e5..86d7edfee1 100644
--- a/common/spl/Kconfig
+++ b/common/spl/Kconfig
@@ -325,12 +325,6 @@ config SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
Address on the MMC to load U-Boot from, when the MMC is being used
in raw mode. Units: MMC sectors (1 sector = 512 bytes).
-config SYS_MMCSD_RAW_MODE_EMMC_BOOT_PARTITION
- int "Number of the eMMC boot partition to use"
- default 1
- help
- eMMC boot partition number to use when the eMMC in raw mode.
-
config SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
bool "MMC Raw mode: by partition"
help
@@ -359,6 +353,28 @@ config SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION_TYPE
Partition Type on the MMC to load U-Boot from, when the MMC is being
used in raw mode.
+config SUPPORT_EMMC_BOOT_OVERRIDE_PART_CONFIG
+ bool "Override eMMC EXT_CSC_PART_CONFIG by user defined partition"
+ depends on SUPPORT_EMMC_BOOT
+ help
+ eMMC boot partition is normally configured by the bits of the EXT_CSD
+ register (EXT_CSC_PART_CONFIG), BOOT_PARTITION_ENABLE field. In some
+ cases it might be required in SPL to load the image from different
+ partition than the partition selected by EXT_CSC_PART_CONFIG register.
+ Enable this option if you intend to use an eMMC boot partition other
+ then selected via EXT_CSC_PART_CONFIG register and specify the custom
+ partition number by the CONFIG_SYS_MMCSD_RAW_MODE_EMMC_BOOT_PARTITION
+ option.
+
+config SYS_MMCSD_RAW_MODE_EMMC_BOOT_PARTITION
+ int "Number of the eMMC boot partition to use"
+ depends on SUPPORT_EMMC_BOOT_OVERRIDE_PART_CONFIG
+ default 1
+ help
+ eMMC boot partition number to use when the eMMC in raw mode and
+ the eMMC EXT_CSC_PART_CONFIG selection should be overridden in SPL
+ by user defined partition number.
+
config SPL_CRC32_SUPPORT
bool "Support CRC32"
default y if SPL_LEGACY_IMAGE_SUPPORT
--
2.17.1
next reply other threads:[~2019-10-18 19:38 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-18 19:38 Anatolij Gustschin [this message]
2019-10-18 20:28 ` [U-Boot] [PATCH] spl: mmc: make eMMC HW boot partition configuration optional Lukasz Majewski
2019-10-19 14:25 ` Tom Rini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20191018193833.8481-1-agust@denx.de \
--to=agust@denx.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox