mirror of
https://github.com/frank-w/u-boot.git
synced 2026-01-12 14:22:58 +08:00
memsize: Fix for bug in memory sizing code
The original memory sizing code in get_ram_size clobbers the word at the base address, but forgets to restore it. Signed-off-by: Iwo Mergler <Iwo.Mergler@netcommwireless.com>
This commit is contained in:
@@ -73,6 +73,7 @@ long get_ram_size(long *base, long maxsize)
|
||||
}
|
||||
return (0);
|
||||
}
|
||||
*addr = save[i];
|
||||
|
||||
for (cnt = 1; cnt < maxsize / sizeof (long); cnt <<= 1) {
|
||||
addr = base + cnt; /* pointer arith! */
|
||||
|
||||
Reference in New Issue
Block a user