Kevin O'Connor wrote:
On Tue, Mar 15, 2011 at 11:29:21PM +0100, Sebastian Herbszt wrote:
I was now able to reproduce it:
[...]
It happens because your Bochs 2.4.5 version was compiled without x86-64 support and --enable-long-phy-address and only supports 32-bit phys_bits. You can recompile it or upgrade to 2.4.6 to fix this.
It sounds like SeaBIOS should be able to detect this at runtime and apply the right mask. The mtrr code in seabios came from Bochs BIOS - which I think was just for kvm. So, maybe just some tweaks are needed here.
-Kevin
A Bochs CPU level 6 processor should support 36 bits. SeaBIOS assumes this and sets phys_bits to 36. If CPUID leaf 0x80000008 is available this assumption is modified and the supplied value is used. The Bochs CPU code suggests this leaf is only available on 64-bit CPUs. If you compile Bochs 2.4.5 without --enable-long-phy-address the valid 36 bit assumption is violated and you get a family 6 CPU with only 32 bits. I don't think trying to fix the detection is worth it, because the problem disappears with Bochs version 2.4.6 or --enable-long-phy-address on older versions.
Sebastian