From 136c69ad7917f23d401c3a794cd0f5a4ab2230de Mon Sep 17 00:00:00 2001 From: Steve Sakoman Date: Thu, 30 Sep 2010 21:46:52 -0700 Subject: ARMV7: OMAP3: Fix bug in get_sdr_cs_offset() This patch fixes a typo in the routine to calculate the cs offset based upon the contents of the SDRC cs_cfg register. This function mistakenly shifts the CS1STARTLOW field 17 bits right instead of 17 bits left. This hasn't been an issue to date because all OMAP3 boards currently are configured to have zeros in this field. Reported-by: Peter Maydell Signed-off-by: Steve Sakoman --- arch/arm/cpu/armv7/omap3/sdrc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch/arm/cpu/armv7') diff --git a/arch/arm/cpu/armv7/omap3/sdrc.c b/arch/arm/cpu/armv7/omap3/sdrc.c index 2719bb53a7..6c419f5b93 100644 --- a/arch/arm/cpu/armv7/omap3/sdrc.c +++ b/arch/arm/cpu/armv7/omap3/sdrc.c @@ -99,7 +99,7 @@ u32 get_sdr_cs_offset(u32 cs) return 0; offset = readl(&sdrc_base->cs_cfg); - offset = (offset & 15) << 27 | (offset & 0x30) >> 17; + offset = (offset & 15) << 27 | (offset & 0x30) << 17; return offset; } -- cgit From 57b512b2ecc9c7a6c8a39c5356ea80fc3164d9e4 Mon Sep 17 00:00:00 2001 From: Steve Sakoman Date: Wed, 29 Sep 2010 20:59:51 -0700 Subject: ARMV7: OMAP4: Implement relocation for Panda and OMAP4430SDP This patch fixes the build breakage introduced by the recent relocation changes for ARMV7 Signed-off-by: Steve Sakoman --- arch/arm/cpu/armv7/omap4/board.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'arch/arm/cpu/armv7') diff --git a/arch/arm/cpu/armv7/omap4/board.c b/arch/arm/cpu/armv7/omap4/board.c index 8c1f3953ed..24a66f5b94 100644 --- a/arch/arm/cpu/armv7/omap4/board.c +++ b/arch/arm/cpu/armv7/omap4/board.c @@ -102,8 +102,13 @@ int dram_init(void) { DECLARE_GLOBAL_DATA_PTR; +#if defined(CONFIG_SYS_ARM_WITHOUT_RELOC) gd->bd->bi_dram[0].start = 0x80000000; gd->bd->bi_dram[0].size = sdram_size(); +#else + gd->ram_size = sdram_size(); +#endif + return 0; } -- cgit