Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=253abdee5ec2edd0a7f6dc2358bef42e3fdf1f39
Commit:     253abdee5ec2edd0a7f6dc2358bef42e3fdf1f39
Parent:     7e66f350cfc853043bfa71b281581dd6f92fa347
Author:     Yang, Sheng <[EMAIL PROTECTED]>
AuthorDate: Thu Aug 16 13:01:00 2007 +0300
Committer:  Avi Kivity <[EMAIL PROTECTED]>
CommitDate: Sat Oct 13 10:18:23 2007 +0200

    KVM: Communicate cr8 changes to userspace
    
    This allows running 64-bit Windows.
    
    Signed-off-by: Sheng Yang <[EMAIL PROTECTED]>
    Signed-off-by: Avi Kivity <[EMAIL PROTECTED]>
---
 drivers/kvm/vmx.c   |    3 ++-
 include/linux/kvm.h |    1 +
 2 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c
index a9b4cb5..cd999c0 100644
--- a/drivers/kvm/vmx.c
+++ b/drivers/kvm/vmx.c
@@ -1831,7 +1831,8 @@ static int handle_cr(struct kvm_vcpu *vcpu, struct 
kvm_run *kvm_run)
                        vcpu_load_rsp_rip(vcpu);
                        set_cr8(vcpu, vcpu->regs[reg]);
                        skip_emulated_instruction(vcpu);
-                       return 1;
+                       kvm_run->exit_reason = KVM_EXIT_SET_TPR;
+                       return 0;
                };
                break;
        case 2: /* clts */
diff --git a/include/linux/kvm.h b/include/linux/kvm.h
index 91a446f..1d5a49c 100644
--- a/include/linux/kvm.h
+++ b/include/linux/kvm.h
@@ -46,6 +46,7 @@ enum kvm_exit_reason {
        KVM_EXIT_SHUTDOWN         = 8,
        KVM_EXIT_FAIL_ENTRY       = 9,
        KVM_EXIT_INTR             = 10,
+       KVM_EXIT_SET_TPR          = 11
 };
 
 /* for KVM_RUN, returned by mmap(vcpu_fd, offset=0) */
-
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