diff options
Diffstat (limited to 'board/samsung')
-rw-r--r-- | board/samsung/common/board.c | 10 | ||||
-rw-r--r-- | board/samsung/odroid/odroid.c | 4 |
2 files changed, 8 insertions, 6 deletions
diff --git a/board/samsung/common/board.c b/board/samsung/common/board.c index 6c7f59be871..2e17da8a7a4 100644 --- a/board/samsung/common/board.c +++ b/board/samsung/common/board.c @@ -82,13 +82,19 @@ int board_init(void) } boot_temp_check(); #endif +#ifdef CONFIG_TZSW_RESERVED_DRAM_SIZE + /* The last few MB of memory can be reserved for secure firmware */ + ulong size = CONFIG_TZSW_RESERVED_DRAM_SIZE; + gd->ram_size -= size; + gd->bd->bi_dram[CONFIG_NR_DRAM_BANKS - 1].size -= size; +#endif return exynos_init(); } int dram_init(void) { - int i; + unsigned int i; u32 addr; for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++) { @@ -100,7 +106,7 @@ int dram_init(void) void dram_init_banksize(void) { - int i; + unsigned int i; u32 addr, size; for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++) { diff --git a/board/samsung/odroid/odroid.c b/board/samsung/odroid/odroid.c index 6f4b8caea54..ae41c29d925 100644 --- a/board/samsung/odroid/odroid.c +++ b/board/samsung/odroid/odroid.c @@ -427,10 +427,6 @@ int exynos_early_init_f(void) int exynos_init(void) { - /* The last MB of memory is reserved for secure firmware */ - gd->ram_size -= SZ_1M; - gd->bd->bi_dram[CONFIG_NR_DRAM_BANKS - 1].size -= SZ_1M; - board_gpio_init(); return 0; |