public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Ignore DEBUGCTL MSRs
@ 2008-06-24  5:04 Alexander Graf
  2008-06-24 13:40 ` Joerg Roedel
  2008-07-05 12:28 ` Avi Kivity
  0 siblings, 2 replies; 11+ messages in thread
From: Alexander Graf @ 2008-06-24  5:04 UTC (permalink / raw)
  To: kvm; +Cc: joerg.roedel

[-- Attachment #1: Type: text/plain, Size: 394 bytes --]

Netware writes and reads to the DEBUGCTL and LAST*IP MSRs without 
further checks and is really confused to receive a #GP during that. To 
make it happy we should just make them stubs, which is exactly what SVM 
already does.

To support VMX too, I put these in the generic code. Maybe the SVM code 
could be cleaned up to use generic code too.

Signed-off-by: Alexander Graf <agraf@suse.de>



[-- Attachment #2: kvm-netware.patch --]
[-- Type: text/x-patch, Size: 902 bytes --]

diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index fc0721e..02f8490 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -609,6 +609,11 @@ int kvm_set_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 data)
 		pr_unimpl(vcpu, "%s: MSR_IA32_MCG_CTL 0x%llx, nop\n",
 			__func__, data);
 		break;
+	case MSR_IA32_DEBUGCTLMSR:
+	case MSR_IA32_LASTBRANCHFROMIP:
+	case MSR_IA32_LASTBRANCHTOIP:
+	case MSR_IA32_LASTINTFROMIP:
+	case MSR_IA32_LASTINTTOIP:
 	case MSR_IA32_UCODE_REV:
 	case MSR_IA32_UCODE_WRITE:
 		break;
@@ -705,6 +710,11 @@ int kvm_get_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 *pdata)
 	case MSR_IA32_MC0_MISC+16:
 	case MSR_IA32_UCODE_REV:
 	case MSR_IA32_EBL_CR_POWERON:
+	case MSR_IA32_DEBUGCTLMSR:
+	case MSR_IA32_LASTBRANCHFROMIP:
+	case MSR_IA32_LASTBRANCHTOIP:
+	case MSR_IA32_LASTINTFROMIP:
+	case MSR_IA32_LASTINTTOIP:
 		data = 0;
 		break;
 	case MSR_MTRRcap:

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2008-07-22  7:19 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-24  5:04 [PATCH] Ignore DEBUGCTL MSRs Alexander Graf
2008-06-24 13:40 ` Joerg Roedel
2008-06-25  7:41   ` Alexander Graf
2008-07-05 12:27   ` Avi Kivity
2008-07-05 12:28 ` Avi Kivity
2008-07-09 12:48   ` Alexander Graf
2008-07-10 14:01     ` Avi Kivity
2008-07-16  9:26       ` Alexander Graf
2008-07-21  9:05         ` Avi Kivity
2008-07-22  6:00           ` Alexander Graf
2008-07-22  7:19             ` Avi Kivity

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