mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* 2.4.0 memory sizing broken on old x86 machines
@ 2001-01-05 23:22 Mikael Pettersson
  0 siblings, 0 replies; only message in thread
From: Mikael Pettersson @ 2001-01-05 23:22 UTC (permalink / raw)
  To: linux-kernel

Memory sizing for old machines whose BIOSen don't speak E820
got broken in 2.4.0-test13-pre4:

--- v2.4.0-test12/linux/arch/i386/kernel/setup.c	Mon Dec 11 17:59:43 2000
+++ linux/arch/i386/kernel/setup.c	Thu Dec 21 14:01:19 2000
@@ -518,7 +518,7 @@
 
 		e820.nr_map = 0;
 		add_memory_region(0, LOWMEMSIZE(), E820_RAM);
-		add_memory_region(HIGH_MEMORY, mem_size << 10, E820_RAM);
+		add_memory_region(HIGH_MEMORY, (mem_size << 10) - HIGH_MEMORY, E820_RAM);
   	}
 	printk("BIOS-provided physical RAM map:\n");
 	print_memory_map(who);

(This snipped is in setup_memory_region() where legacy (e801 or 88)
memory size info is converted to e820-style.)

BIOS call 0x88 returns extended (above 1M) memory size not total, so
the subtraction "- HIGH_MEMORY" is wrong. The effect is that the
kernel believes the machine to have 1MB less RAM than it actually has
-- not fun on an old 486 with limited RAM to start with :-(

I think this patch should be backed out pronto.

/Mikael
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2001-01-05 23:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-01-05 23:22 2.4.0 memory sizing broken on old x86 machines Mikael Pettersson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®