* [PATCH] qemu-kvm: remove "KVM misreports CPUID" hack
@ 2009-07-03 12:23 Andre Przywara
2009-07-04 15:21 ` Avi Kivity
0 siblings, 1 reply; 2+ messages in thread
From: Andre Przywara @ 2009-07-03 12:23 UTC (permalink / raw)
To: avi; +Cc: kvm, Andre Przywara
This should be no longer necessary.
Effectively reverts 143eb2bd043e82bcf353cf82d33c127f06411d82.
Signed-off-by: Andre Przywara <andre.przywara@amd.com>
---
kvm/libkvm/libkvm-x86.c | 9 ---------
qemu-kvm-x86.c | 9 ---------
2 files changed, 0 insertions(+), 18 deletions(-)
Hi Avi,
I am not sure what caused your problem back in May when you committed this,
but it seems to work without this now. I booted Win7RC 64bit and WinXP 64bit
and saw no problems.
Regards,
Andre.
diff --git a/kvm/libkvm/libkvm-x86.c b/kvm/libkvm/libkvm-x86.c
index 9ca77d5..67f41b4 100644
--- a/kvm/libkvm/libkvm-x86.c
+++ b/kvm/libkvm/libkvm-x86.c
@@ -639,15 +639,6 @@ uint32_t kvm_get_supported_cpuid(kvm_context_t kvm, uint32_t function, int reg)
break;
case R_EDX:
ret = cpuid->entries[i].edx;
- if (function == 1) {
- /* kvm misreports the following features
- */
- ret |= 1 << 12; /* MTRR */
- ret |= 1 << 16; /* PAT */
- ret |= 1 << 7; /* MCE */
- ret |= 1 << 14; /* MCA */
- }
-
/* On Intel, kvm returns cpuid according to
* the Intel spec, so add missing bits
* according to the AMD spec:
diff --git a/qemu-kvm-x86.c b/qemu-kvm-x86.c
index 7505380..2811665 100644
--- a/qemu-kvm-x86.c
+++ b/qemu-kvm-x86.c
@@ -649,15 +649,6 @@ uint32_t kvm_get_supported_cpuid(kvm_context_t kvm, uint32_t function, int reg)
break;
case R_EDX:
ret = cpuid->entries[i].edx;
- if (function == 1) {
- /* kvm misreports the following features
- */
- ret |= 1 << 12; /* MTRR */
- ret |= 1 << 16; /* PAT */
- ret |= 1 << 7; /* MCE */
- ret |= 1 << 14; /* MCA */
- }
-
/* On Intel, kvm returns cpuid according to
* the Intel spec, so add missing bits
* according to the AMD spec:
--
1.6.1.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] qemu-kvm: remove "KVM misreports CPUID" hack
2009-07-03 12:23 [PATCH] qemu-kvm: remove "KVM misreports CPUID" hack Andre Przywara
@ 2009-07-04 15:21 ` Avi Kivity
0 siblings, 0 replies; 2+ messages in thread
From: Avi Kivity @ 2009-07-04 15:21 UTC (permalink / raw)
To: Andre Przywara; +Cc: kvm
On 07/03/2009 03:23 PM, Andre Przywara wrote:
> This should be no longer necessary.
> Effectively reverts 143eb2bd043e82bcf353cf82d33c127f06411d82.
>
> Signed-off-by: Andre Przywara<andre.przywara@amd.com>
> ---
> kvm/libkvm/libkvm-x86.c | 9 ---------
> qemu-kvm-x86.c | 9 ---------
> 2 files changed, 0 insertions(+), 18 deletions(-)
>
> Hi Avi,
>
> I am not sure what caused your problem back in May when you committed this,
> but it seems to work without this now. I booted Win7RC 64bit and WinXP 64bit
> and saw no problems.
>
It's necessary for backwards compatibility. Older kvm versions
misreported these bits, so we need to fix them up in userspace.
--
Do not meddle in the internals of kernels, for they are subtle and quick to panic.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-07-04 15:21 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-07-03 12:23 [PATCH] qemu-kvm: remove "KVM misreports CPUID" hack Andre Przywara
2009-07-04 15:21 ` Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).