summaryrefslogtreecommitdiff
path: root/board/samsung
diff options
context:
space:
mode:
authorChander Kashyap <chander.kashyap@linaro.org>2011-09-20 21:25:04 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2011-11-03 22:56:20 +0100
commit9b3ab1c9758affc4203444c2231169a044d0c5fd (patch)
tree1a25aa3fe9188c5ed72baf1a103285542d6e8f9e /board/samsung
parent5187d8dd5e9dccb4ec598c906f3258d8bc24333c (diff)
downloadu-boot-imx-9b3ab1c9758affc4203444c2231169a044d0c5fd.zip
u-boot-imx-9b3ab1c9758affc4203444c2231169a044d0c5fd.tar.gz
u-boot-imx-9b3ab1c9758affc4203444c2231169a044d0c5fd.tar.bz2
smdkv310: use macro for mmc data read function address
board/samsung/smdkv310/mmc_boot.c: Removed the typedef for "mmc data read API (copy_sd_mmc_to_mem)" as it is used only once and replaced hard-coded API address value by macro. Signed-off-by: Chander Kashyap <chander.kashyap@linaro.org> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
Diffstat (limited to 'board/samsung')
-rw-r--r--board/samsung/smdkv310/mmc_boot.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/board/samsung/smdkv310/mmc_boot.c b/board/samsung/smdkv310/mmc_boot.c
index 2f3e463..d3fc18d 100644
--- a/board/samsung/smdkv310/mmc_boot.c
+++ b/board/samsung/smdkv310/mmc_boot.c
@@ -23,15 +23,16 @@
#include<common.h>
#include<config.h>
-typedef u32(*copy_sd_mmc_to_mem) \
- (u32 start_block, u32 block_count, u32 *dest_addr);
-
-
+/*
+* Copy U-boot from mmc to RAM:
+* COPY_BL2_FNPTR_ADDR: Address in iRAM, which Contains
+* API (Data transfer from mmc to ram)
+*/
void copy_uboot_to_ram(void)
{
- copy_sd_mmc_to_mem copy_bl2 = (copy_sd_mmc_to_mem)(0x00002488);
- copy_bl2(BL2_START_OFFSET,\
- BL2_SIZE_BLOC_COUNT, (u32 *)CONFIG_SYS_TEXT_BASE);
+ u32 (*copy_bl2)(u32, u32, u32) = (void *)COPY_BL2_FNPTR_ADDR;
+
+ copy_bl2(BL2_START_OFFSET, BL2_SIZE_BLOC_COUNT, CONFIG_SYS_TEXT_BASE);
}
void board_init_f(unsigned long bootflag)