summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVanessa Maegima <vanessa.maegima@nxp.com>2016-06-09 15:28:33 -0300
committerStefano Babic <sbabic@denx.de>2016-07-12 17:58:49 +0200
commitd6b0c468189fad76addd09e9796e87ab61c227df (patch)
tree7857f8b71dc45a15e47ea2a556a1a7cfdfd2e949
parent432a8a55478d431e036e695c3f8b9d9e2536f744 (diff)
downloadu-boot-imx-d6b0c468189fad76addd09e9796e87ab61c227df.zip
u-boot-imx-d6b0c468189fad76addd09e9796e87ab61c227df.tar.gz
u-boot-imx-d6b0c468189fad76addd09e9796e87ab61c227df.tar.bz2
mx6sxsabresd: Avoid hardcoded RAM size
Instead of passing the total RAM size via PHYS_SDRAM_SIZE option, we should better use imx_ddr_size() function, which automatically determines the RAM size. Signed-off-by: Vanessa Maegima <vanessa.maegima@nxp.com>
-rw-r--r--board/freescale/mx6sxsabresd/mx6sxsabresd.c2
-rw-r--r--include/configs/mx6sxsabresd.h1
2 files changed, 1 insertions, 2 deletions
diff --git a/board/freescale/mx6sxsabresd/mx6sxsabresd.c b/board/freescale/mx6sxsabresd/mx6sxsabresd.c
index 25e009e..8d95c51 100644
--- a/board/freescale/mx6sxsabresd/mx6sxsabresd.c
+++ b/board/freescale/mx6sxsabresd/mx6sxsabresd.c
@@ -64,7 +64,7 @@ DECLARE_GLOBAL_DATA_PTR;
int dram_init(void)
{
- gd->ram_size = PHYS_SDRAM_SIZE;
+ gd->ram_size = imx_ddr_size();
return 0;
}
diff --git a/include/configs/mx6sxsabresd.h b/include/configs/mx6sxsabresd.h
index 183a759..9281fee 100644
--- a/include/configs/mx6sxsabresd.h
+++ b/include/configs/mx6sxsabresd.h
@@ -132,7 +132,6 @@
/* Physical Memory Map */
#define CONFIG_NR_DRAM_BANKS 1
#define PHYS_SDRAM MMDC0_ARB_BASE_ADDR
-#define PHYS_SDRAM_SIZE SZ_1G
#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM
#define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR