Skip to contentSkip to conversation

KVM: Dynamically determine which msrs to load and save

PATCH New Avi Kivity 1 participant 1 message Oct 30, 2006 KVM

lore
Share & tools
lore

Avi Kivity

author
#0 lore raw

PATCH 1/1 KVM: Dynamically determine which msrs to load and save

Different cpus have different msrs available. The Core (not Core 2) cpu lacks the STAR msr, so kvm faults when accessing it.

Fix by determining which msrs are available dynamically, and only loading and saving available msrs.

drivers/kvm/kvm.h +1 -0
Index: linux-2.6/drivers/kvm/kvm.h
===================================================================
@@ -167,6 +167,7 @@ struct kvm_vcpu {
 	unsigned long cr8;
 	u64 shadow_efer;
 	u64 apic_base;
+	int nmsrs;
 	struct vmx_msr_entry *guest_msrs;
 	struct vmx_msr_entry *host_msrs;
 
drivers/kvm/kvm_main.c +43 -31

143 lines not on this page · raw message

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642