]> git.sur5r.net Git - u-boot/commitdiff
common/memsize.c: Increase save array for supporting memory size > 4GB
authorTien Fong Chee <tien.fong.chee@intel.com>
Wed, 20 Jun 2018 07:06:20 +0000 (15:06 +0800)
committerTom Rini <trini@konsulko.com>
Tue, 10 Jul 2018 20:55:59 +0000 (16:55 -0400)
In ARM 64-bits, memory size can be supported is more than 4GB,
hence increasing save array is needed to cope with testing larger memory.

Signed-off-by: Tien Fong Chee <tien.fong.chee@intel.com>
common/memsize.c

index 5670e95137116bcb7b87ea20203226614bcc9dd3..13b004778667f98d15b6f8dfbcbdea808ab0e0a8 100644 (file)
@@ -26,7 +26,7 @@ DECLARE_GLOBAL_DATA_PTR;
 long get_ram_size(long *base, long maxsize)
 {
        volatile long *addr;
-       long           save[31];
+       long           save[BITS_PER_LONG - 1];
        long           save_base;
        long           cnt;
        long           val;