]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
sunxi: DRAM: fix H3 DRAM size display on aarch64
authorAndre Przywara <andre.przywara@arm.com>
Mon, 2 Jan 2017 11:48:44 +0000 (11:48 +0000)
committerJagan Teki <jagan@openedev.com>
Wed, 4 Jan 2017 15:37:43 +0000 (16:37 +0100)
Fix the output of the DRAM size on AArch64 SPLs.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Alexander Graf <agraf@suse.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
arch/arm/mach-sunxi/dram_sun8i_h3.c

index 1311edaf325b69a358275dc9687bc991864b0793..9f7cc7fd4ccdcec499519ed0d89dd0f8687bc7cc 100644 (file)
@@ -664,6 +664,6 @@ unsigned long sunxi_dram_init(void)
        mctl_auto_detect_dram_size(&para);
        mctl_set_cr(&para);
 
-       return (1 << (para.row_bits + 3)) * para.page_size *
+       return (1UL << (para.row_bits + 3)) * para.page_size *
                                                (para.dual_rank ? 2 : 1);
 }