]> git.ipfire.org Git - people/ms/u-boot.git/blobdiff - arch/arm/mach-imx/spl.c
i.MX6Q: spl: Fix falcon to use dram_init_banksize
[people/ms/u-boot.git] / arch / arm / mach-imx / spl.c
index 3853e7739d2e665d87f3f0d6d3711c25a099d880..258578ac25b4fd6efee695c703f4d81bdb9bbff4 100644 (file)
@@ -15,6 +15,8 @@
 #include <spl.h>
 #include <asm/mach-imx/hab.h>
 
+DECLARE_GLOBAL_DATA_PTR;
+
 #if defined(CONFIG_MX6)
 /* determine boot device from SRC_SBMR1 (BOOT_CFG[4:1]) or SRC_GPR9 register */
 u32 spl_boot_device(void)
@@ -128,3 +130,13 @@ __weak void __noreturn jump_to_image_no_args(struct spl_image_info *spl_image)
 }
 
 #endif
+
+#if defined(CONFIG_MX6) && defined(CONFIG_SPL_OS_BOOT)
+int dram_init_banksize(void)
+{
+       gd->bd->bi_dram[0].start = CONFIG_SYS_SDRAM_BASE;
+       gd->bd->bi_dram[0].size = imx_ddr_size();
+
+       return 0;
+}
+#endif