samsung:board: dram_init(): alloc memory to store fdt dram info
authorPrzemyslaw Marczak <p.marczak@samsung.com>
Thu, 18 Sep 2014 14:20:29 +0000 (16:20 +0200)
committerLukasz Majewski <l.majewski@samsung.com>
Thu, 30 Oct 2014 08:34:02 +0000 (09:34 +0100)
commite4443070f8ce408cffe9097e5dd085096adacb51
treed71bc95bc67978b55111936e74dccc6bed5406b0
parent666229dae65f993030f91ab3a142773b8f3894db
samsung:board: dram_init(): alloc memory to store fdt dram info

For CONFIG_OF_MULTI the dram_init() function gets memory information
from the device tree blob by the call to fdtdec_decode_memory().
The same is done second time in dram_init_banksize() - this was the
simplest because board info structure is not initialized at dram_init()
stage.

This change uses malloc and gd->priv pointer to store the memory banks
parameters and next uses it in dram_init_banksize().

Thanks to this change, the boot time decreases, because, the function
fdtdec_decode_memory() is called only once.

Change-Id: I8f357c6a641d4440f32d2fe24d7e1e2dc5bc4a3d
Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
board/samsung/common/board.c
include/samsung/multi-plat.h [new file with mode: 0644]