Skip to content

Commit

Permalink
KVM: VMX: Fix reporting of unhandled EPT violations
Browse files Browse the repository at this point in the history
Instead of returning -ENOTSUPP, exit normally but indicate the hardware
exit reason.

Signed-off-by: Avi Kivity <[email protected]>
  • Loading branch information
avikivity committed Sep 10, 2009
1 parent 6de4f3a commit 596ae89
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions arch/x86/kvm/vmx.c
Original file line number Diff line number Diff line change
Expand Up @@ -3153,8 +3153,8 @@ static int handle_ept_violation(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)
printk(KERN_ERR "EPT: Exit qualification is 0x%lx\n",
(long unsigned int)exit_qualification);
kvm_run->exit_reason = KVM_EXIT_UNKNOWN;
kvm_run->hw.hardware_exit_reason = 0;
return -ENOTSUPP;
kvm_run->hw.hardware_exit_reason = EXIT_REASON_EPT_VIOLATION;
return 0;
}

gpa = vmcs_read64(GUEST_PHYSICAL_ADDRESS);
Expand Down

0 comments on commit 596ae89

Please sign in to comment.