From 95e68ce9c9279521866d997b80cb206abe9de72e Mon Sep 17 00:00:00 2001 From: "Yang, Sheng" Date: Thu, 16 Aug 2007 13:01:00 +0300 Subject: [PATCH] --- yaml --- r: 68392 b: refs/heads/master c: 253abdee5ec2edd0a7f6dc2358bef42e3fdf1f39 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/kvm/vmx.c | 3 ++- trunk/include/linux/kvm.h | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 7731d61f554e..3f5cf59af497 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 7e66f350cfc853043bfa71b281581dd6f92fa347 +refs/heads/master: 253abdee5ec2edd0a7f6dc2358bef42e3fdf1f39 diff --git a/trunk/drivers/kvm/vmx.c b/trunk/drivers/kvm/vmx.c index a9b4cb51dec8..cd999c0a24c4 100644 --- a/trunk/drivers/kvm/vmx.c +++ b/trunk/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/trunk/include/linux/kvm.h b/trunk/include/linux/kvm.h index 91a446f450b8..1d5a49cdda3b 100644 --- a/trunk/include/linux/kvm.h +++ b/trunk/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) */