patch-2.3.32 linux/arch/arm/mm/init.c

Next file: linux/arch/arm/mm/mm-armv.c
Previous file: linux/arch/arm/kernel/traps.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.31/linux/arch/arm/mm/init.c linux/arch/arm/mm/init.c
@@ -249,7 +249,7 @@
 	initpages = &__init_end - &__init_begin;
 
 	max_mapnr   = max_low_pfn;
-	high_memory = (void *)__va(max_low_pfn * PAGE_SIZE);
+	high_memory = (void *)__va(PHYS_OFFSET + max_low_pfn * PAGE_SIZE);
 
 	/*
 	 * We may have non-contiguous memory.  Setup the PageSkip stuff,
@@ -273,12 +273,12 @@
 		printk(" %ldMB", meminfo.bank[i].size >> 20);
 	}
 
-	printk(" = %luMB total\n", num_physpages >> (20 - PAGE_SHIFT)); 
+	printk(" = %luMB total\n", num_physpages >> (20 - PAGE_SHIFT));
 	printk("Memory: %luKB available (%dK code, %dK data, %dK init)\n",
 		(unsigned long) nr_free_pages() << (PAGE_SHIFT-10),
 		codepages >> 10, datapages >> 10, initpages >> 10);
 
-	if (PAGE_SIZE >= 16384 && max_mapnr <= 128) {
+	if (PAGE_SIZE >= 16384 && num_physpages <= 128) {
 		extern int sysctl_overcommit_memory;
 		/*
 		 * On a machine this small we won't get

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)