Commit 4520a2f28eade14b97618b37148ac615e78783df
Committed by
Pantelis Antoniou
1 parent
9108b315f2
Exists in
master
and in
50 other branches
powerpc: mmc: Add corenet devices support in esdhc spl
Existing eSDHC SPL framework assumes booting from sd-image with boot_format header which contains final u-boot Image offset and size. No such header is present in case of corenet devices like T1040 as corenet deivces use PBI-RCW based intialization. So, for corenet deives, SPL bootloader use values provided at compilation time. These values can be defined in board specific config file. Signed-off-by: Priyanka Jain <Priyanka.Jain@freescale.com> Acked-by: Pantelis Antoniou <panto@antoniou-consulting.com>
Showing 1 changed file with 5 additions and 0 deletions Side-by-side Diff
drivers/mmc/fsl_esdhc_spl.c
... | ... | @@ -42,6 +42,10 @@ |
42 | 42 | hang(); |
43 | 43 | } |
44 | 44 | |
45 | +#ifdef CONFIG_FSL_CORENET | |
46 | + offset = CONFIG_SYS_MMC_U_BOOT_OFFS; | |
47 | + code_len = CONFIG_SYS_MMC_U_BOOT_SIZE; | |
48 | +#else | |
45 | 49 | blklen = mmc->read_bl_len; |
46 | 50 | tmp_buf = malloc(blklen); |
47 | 51 | if (!tmp_buf) { |
... | ... | @@ -91,6 +95,7 @@ |
91 | 95 | /* |
92 | 96 | * Load U-Boot image from mmc into RAM |
93 | 97 | */ |
98 | +#endif | |
94 | 99 | blk_start = ALIGN(offset, mmc->read_bl_len) / mmc->read_bl_len; |
95 | 100 | blk_cnt = ALIGN(code_len, mmc->read_bl_len) / mmc->read_bl_len; |
96 | 101 | err = mmc->block_dev.block_read(0, blk_start, blk_cnt, |