diff --git a/common/spl/spl_fit.c b/common/spl/spl_fit.c index 72ae8f4c50..ebfd5bc2e3 100644 --- a/common/spl/spl_fit.c +++ b/common/spl/spl_fit.c @@ -10,6 +10,7 @@ #include #include #include +#include #ifndef CONFIG_SYS_BOOTM_LEN #define CONFIG_SYS_BOOTM_LEN (64 << 20) @@ -196,6 +197,10 @@ static int spl_load_fit_image(struct spl_load_info *info, ulong sector, return -ENOENT; load_ptr = (load_addr + align_len) & ~align_len; +#ifdef CONFIG_ROCKCHIP_RK3399 + if ((load_ptr & 0xffff0000) == CONFIG_ROCKCHIP_IRAM_START_ADDR) + load_ptr = (ulong)memalign(ARCH_DMA_MINALIGN, len); +#endif length = len; overhead = get_aligned_image_overhead(info, offset);