summaryrefslogtreecommitdiff
path: root/board/freescale/mpc837xemds
diff options
context:
space:
mode:
authorAnton Vorontsov <avorontsov@ru.mvista.com>2008-09-11 17:35:36 (GMT)
committerKim Phillips <kim.phillips@freescale.com>2008-09-24 14:58:33 (GMT)
commitd26154c9a692586b66eb6d1f8e1b67c75e40ea70 (patch)
tree907998ee6fbf1b398b5db7596bb28941a540322f /board/freescale/mpc837xemds
parent8fd4166c467a46773f80208bda1ec3b4757747bc (diff)
downloadu-boot-fsl-qoriq-d26154c9a692586b66eb6d1f8e1b67c75e40ea70.tar.xz
mpc83xx: spd_sdram: fix ddr sdram base address assignment bug
The spd_dram code shifts the base address, then masks 20 bits, but forgets to shift the base address back. Fix this by just masking the base address correctly. Found this bug while trying to relocate a DDR memory at the base != 0. Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com> Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Diffstat (limited to 'board/freescale/mpc837xemds')
-rw-r--r--board/freescale/mpc837xemds/mpc837xemds.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/board/freescale/mpc837xemds/mpc837xemds.c b/board/freescale/mpc837xemds/mpc837xemds.c
index 40f1e63..8003ec1 100644
--- a/board/freescale/mpc837xemds/mpc837xemds.c
+++ b/board/freescale/mpc837xemds/mpc837xemds.c
@@ -108,7 +108,7 @@ int fixed_sdram(void)
u32 msize = CFG_DDR_SIZE * 1024 * 1024;
u32 msize_log2 = __ilog2(msize);
- im->sysconf.ddrlaw[0].bar = CFG_DDR_SDRAM_BASE >> 12;
+ im->sysconf.ddrlaw[0].bar = CFG_DDR_SDRAM_BASE & 0xfffff000;
im->sysconf.ddrlaw[0].ar = LBLAWAR_EN | (msize_log2 - 1);
#if (CFG_DDR_SIZE != 512)