From mboxrd@z Thu Jan 1 00:00:00 1970 From: Heiko Schocher Date: Mon, 25 Jul 2016 10:16:49 +0200 Subject: [U-Boot] [PATCH 2/5] aristainetos: Use imx_ddr_size() for calculating the DDR size In-Reply-To: <1469291022-15677-2-git-send-email-festevam@gmail.com> References: <1469291022-15677-1-git-send-email-festevam@gmail.com> <1469291022-15677-2-git-send-email-festevam@gmail.com> Message-ID: <5795CAF1.9010504@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello Fabio, Am 23.07.2016 um 18:23 schrieb Fabio Estevam: > From: Fabio Estevam > > 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 > Signed-off-by: Fabio Estevam > --- > board/aristainetos/aristainetos.c | 2 +- > include/configs/aristainetos-common.h | 1 - > 2 files changed, 1 insertion(+), 2 deletions(-) Thanks! Acked-by: Heiko Schocher bye, Heiko > > diff --git a/board/aristainetos/aristainetos.c b/board/aristainetos/aristainetos.c > index e95ec81..d1e6850 100644 > --- a/board/aristainetos/aristainetos.c > +++ b/board/aristainetos/aristainetos.c > @@ -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; > } > diff --git a/include/configs/aristainetos-common.h b/include/configs/aristainetos-common.h > index d87d40c..640227b 100644 > --- a/include/configs/aristainetos-common.h > +++ b/include/configs/aristainetos-common.h > @@ -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) > -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany