diff options
author | Heiko Schocher <hs@denx.de> | 2011-10-06 20:40:00 (GMT) |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2011-10-23 21:32:44 (GMT) |
commit | 7b5d61b5a3dd6c6f8f0723941beb700277de9407 (patch) | |
tree | 3733c9abd8ec88a819c3979447dcde01944fdcdc /post | |
parent | 23d8f778c8f81b25d3bcecb8c4cdc97d6685af25 (diff) | |
download | u-boot-7b5d61b5a3dd6c6f8f0723941beb700277de9407.tar.xz |
arm, post, memory: fix bug if sdram base != 0x00000000
commit 8d3fcb5e60b6c8e1d530dbc2e2e33ec6a44670da breaks post
memory support for sdram base != 0x00000000. Fix this.
Signed-off-by: Heiko Schocher <hs@denx.de>
Cc: Valentin Longchamp <valentin.longchamp@keymile.com>
Cc: Holger Brunck <holger.brunck@keymile.com>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'post')
-rw-r--r-- | post/drivers/memory.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/post/drivers/memory.c b/post/drivers/memory.c index 69973c0..d25e323 100644 --- a/post/drivers/memory.c +++ b/post/drivers/memory.c @@ -466,10 +466,11 @@ static int memory_post_test_regions(unsigned long start, unsigned long size) for (i = 0; i < (size >> 20) && (!ret); i++) { if (!ret) - ret = memory_post_test_patterns(i << 20, 0x800); - if (!ret) - ret = memory_post_test_patterns((i << 20) + 0xff800, + ret = memory_post_test_patterns(start + (i << 20), 0x800); + if (!ret) + ret = memory_post_test_patterns(start + (i << 20) + + 0xff800, 0x800); } return ret; |