diff options
author | aurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-04-27 21:12:55 +0000 |
---|---|---|
committer | aurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-04-27 21:12:55 +0000 |
commit | 00f82b8a3166514f634c1c010c3b6175bcc6403b (patch) | |
tree | 31d41d48d7207ee9be02483f6a3c951f9075c371 /target-i386/helper.c | |
parent | c1d00dc0b432813f29baac7ec62e4cec09949765 (diff) |
Use correct types to enable > 2G support, based on a patch from
Anthony Liguori.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4265 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-i386/helper.c')
-rw-r--r-- | target-i386/helper.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/target-i386/helper.c b/target-i386/helper.c index b2c829926c..c3d307eeb4 100644 --- a/target-i386/helper.c +++ b/target-i386/helper.c @@ -1747,7 +1747,21 @@ void helper_cpuid(void) break; case 0x80000008: /* virtual & phys address size in low 2 bytes. */ - EAX = 0x00003028; +/* XXX: This value must match the one used in the MMU code. */ +#if defined(TARGET_X86_64) +# if defined(USE_KQEMU) + EAX = 0x00003020; /* 48 bits virtual, 32 bits physical */ +# else +/* XXX: The physical address space is limited to 42 bits in exec.c. */ + EAX = 0x00003028; /* 48 bits virtual, 40 bits physical */ +# endif +#else +# if defined(USE_KQEMU) + EAX = 0x00000020; /* 32 bits physical */ +# else + EAX = 0x00000024; /* 36 bits physical */ +# endif +#endif EBX = 0; ECX = 0; EDX = 0; |