Christian Hesse wrote:
>> It may be the cpuid strangeness that Rusty saw.  Can you try the
>> attached patch?
>>     
>
> No, that does not help.
>   

Ah, I see it.  The Core processor does not have the STAR msr.

Can you try backing out the attached patch?

-- 
Do not meddle in the internals of kernels, for they are subtle and quick to 
panic.

commit 5c828f83928f186320d74627089122ebc9ea98ce
Author: Avi Kivity <[EMAIL PROTECTED]>
Date:   Thu Apr 19 14:28:44 2007 +0300

    KVM: VMX: Only save/restore MSR_K6_STAR if necessary
    
    Intel hosts only support syscall/sysret in long more (and only if efer.sce
    is enabled), so only reload the related MSR_K6_STAR if the guest will
    actually be able to use it.
    
    This reduces vmexit cost by about 500 cycles (6400 -> 5870) on my setup.
    
    Signed-off-by: Avi Kivity <[EMAIL PROTECTED]>

diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c
index b61d4dd..3f43f50 100644
--- a/drivers/kvm/vmx.c
+++ b/drivers/kvm/vmx.c
@@ -323,6 +323,16 @@ static void setup_msrs(struct kvm_vcpu *vcpu)
 		nr_skip = NR_64BIT_MSRS;
 	nr_good_msrs = vcpu->nmsrs - nr_skip;
 
+	/*
+	 * MSR_K6_STAR is only needed on long mode guests, and only
+	 * if efer.sce is enabled.
+	 */
+	--nr_good_msrs;
+#if CONFIG_X86_64
+	if (is_long_mode(vcpu) && (vcpu->shadow_efer & EFER_SCE))
+		++nr_good_msrs;
+#endif
+
 	vmcs_writel(VM_ENTRY_MSR_LOAD_ADDR,
 		    virt_to_phys(vcpu->guest_msrs + nr_skip));
 	vmcs_writel(VM_EXIT_MSR_STORE_ADDR,
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

Reply via email to