]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - arch/arm/mm/init.c
Merge branches 'fixes', 'pgt-next' and 'versatile' into devel
[karo-tx-linux.git] / arch / arm / mm / init.c
index cddd684364dab2f6503d20132d8f5047615a2a52..b3b0f0f5053dfe791eaaa1fc66d9a014350c4d9b 100644 (file)
@@ -350,7 +350,7 @@ void __init bootmem_init(void)
         */
        arm_bootmem_free(min, max_low, max_high);
 
-       high_memory = __va((max_low << PAGE_SHIFT) - 1) + 1;
+       high_memory = __va(((phys_addr_t)max_low << PAGE_SHIFT) - 1) + 1;
 
        /*
         * This doesn't seem to be used by the Linux memory manager any
@@ -398,8 +398,8 @@ free_memmap(unsigned long start_pfn, unsigned long end_pfn)
         * Convert to physical addresses, and
         * round start upwards and end downwards.
         */
-       pg = PAGE_ALIGN(__pa(start_pg));
-       pgend = __pa(end_pg) & PAGE_MASK;
+       pg = (unsigned long)PAGE_ALIGN(__pa(start_pg));
+       pgend = (unsigned long)__pa(end_pg) & PAGE_MASK;
 
        /*
         * If there are free pages between these,