Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=de979caacca51c929d2cc2f0f79611ee4a1bc8a5
Commit:     de979caacca51c929d2cc2f0f79611ee4a1bc8a5
Parent:     d27d4aca184ac0ca6b7e32caf79e1c2b91959be9
Author:     Joerg Roedel <[EMAIL PROTECTED]>
AuthorDate: Mon Feb 19 14:37:46 2007 +0200
Committer:  Avi Kivity <[EMAIL PROTECTED]>
CommitDate: Sun Mar 4 11:12:39 2007 +0200

    KVM: vmx: hack set_cr0_no_modeswitch() to actually do modeswitch
    
    The whole thing is rotten, but this allows vmx to boot with the guest reboot
    fix.
    
    Signed-off-by: Markus Rechberger <[EMAIL PROTECTED]>
    Signed-off-by: Joerg Roedel <[EMAIL PROTECTED]>
    Signed-off-by: Avi Kivity <[EMAIL PROTECTED]>
---
 drivers/kvm/vmx.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c
index ff3bfc5..e02c598 100644
--- a/drivers/kvm/vmx.c
+++ b/drivers/kvm/vmx.c
@@ -791,6 +791,9 @@ static void vmx_set_cr0(struct kvm_vcpu *vcpu, unsigned 
long cr0)
  */
 static void vmx_set_cr0_no_modeswitch(struct kvm_vcpu *vcpu, unsigned long cr0)
 {
+       if (!vcpu->rmode.active && !(cr0 & CR0_PE_MASK))
+               enter_rmode(vcpu);
+
        vcpu->rmode.active = ((cr0 & CR0_PE_MASK) == 0);
        update_exception_bitmap(vcpu);
        vmcs_writel(CR0_READ_SHADOW, cr0);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to