]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
aristainetos: Use imx_ddr_size() for calculating the DDR size
authorFabio Estevam <fabio.estevam@nxp.com>
Sat, 23 Jul 2016 16:23:39 +0000 (13:23 -0300)
committerStefano Babic <sbabic@denx.de>
Thu, 28 Jul 2016 11:27:20 +0000 (13:27 +0200)
imx_ddr_size() can be used to calculate the DDR size in runtime.

By using this function we no longer need to define PHYS_SDRAM_SIZE.

Cc: Heiko Schocher <hs@denx.de>
Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Acked-by: Heiko Schocher <hs@denx.de>
board/aristainetos/aristainetos.c
include/configs/aristainetos-common.h

index e95ec81760f2082c91bdf4ad6409416ff24c8f4c..d1e6850636a1a86f9a56ffaf131798b5c804453b 100644 (file)
@@ -102,7 +102,7 @@ iomux_v3_cfg_t const usdhc1_pads[] = {
 
 int dram_init(void)
 {
-       gd->ram_size = get_ram_size((void *)PHYS_SDRAM, PHYS_SDRAM_SIZE);
+       gd->ram_size = imx_ddr_size();
 
        return 0;
 }
index d87d40cc313a2dd38edab584de4e150b16199a69..640227bf9a501d8ac9f13ca5172502b9410f4ff5 100644 (file)
@@ -17,7 +17,6 @@
 
 #define CONFIG_MACH_TYPE       4501
 #define CONFIG_MMCROOT         "/dev/mmcblk0p1"
-#define PHYS_SDRAM_SIZE                (1u * 1024 * 1024 * 1024)
 
 /* Size of malloc() pool */
 #define CONFIG_SYS_MALLOC_LEN          (64 * SZ_1M)