diff options
| author | Pali Rohár <[email protected]> | 2023-01-08 13:16:38 +0100 |
|---|---|---|
| committer | Stefan Roese <[email protected]> | 2023-03-01 06:39:17 +0100 |
| commit | 353bdaecee9874b21d6feb3cabfe369194197b1e (patch) | |
| tree | c2370e43bd05ba2ac59e307e1bd9d2e528cf7e17 | |
| parent | 8562a1c6a4572550f752d4deca95d9efdd9b5265 (diff) | |
arm: mvebu: spl: Fix parsing SDIO kwbimage
Despite the official specification, Marvell BootROM does not interpret
srcaddr from SDIO image as offset in number of sectors (like for SATA
image), but as offset in bytes (like for all other images except SATA).
To process SDIO kwbimage and load U-Boot proper from it in the same way as
Marvell BootROM, it is needed to interpret srcaddr in bytes. This change
fixes booting of U-Boot proper from SPL code stored in SDIO image.
Fixes: 2226ca173486 ("arm: mvebu: Load U-Boot proper binary in SPL code based on kwbimage header")
Signed-off-by: Pali Rohár <[email protected]>
| -rw-r--r-- | arch/arm/mach-mvebu/spl.c | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/arch/arm/mach-mvebu/spl.c b/arch/arm/mach-mvebu/spl.c index 424599286e5..b238ba2f5d9 100644 --- a/arch/arm/mach-mvebu/spl.c +++ b/arch/arm/mach-mvebu/spl.c @@ -196,14 +196,6 @@ int spl_parse_board_header(struct spl_image_info *spl_image, spl_image->offset *= 512; } - /* - * For SDIO (eMMC) srcaddr is specified in number of sectors. - * This expects that sector size is 512 bytes and recalculates - * data offset to bytes. - */ - if (IS_ENABLED(CONFIG_SPL_MMC) && mhdr->blockid == IBR_HDR_SDIO_ID) - spl_image->offset *= 512; - if (spl_image->offset % 4 != 0) { printf("ERROR: Wrong srcaddr (0x%08x) in kwbimage\n", spl_image->offset); |
