Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 146544
b: refs/heads/master
c: 8317c29
h: refs/heads/master
v: v3
  • Loading branch information
Gleb Natapov authored and Avi Kivity committed Jun 10, 2009
1 parent 6efed43 commit 25be7b2
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ba8afb6b0a2c7e06da760ffe5d078245058619b5
refs/heads/master: 8317c298eab14cc20e2de5289743ff0d4c5a6b30
11 changes: 9 additions & 2 deletions trunk/arch/x86/kvm/svm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1828,6 +1828,7 @@ static int task_switch_interception(struct vcpu_svm *svm,
int reason;
int int_type = svm->vmcb->control.exit_int_info &
SVM_EXITINTINFO_TYPE_MASK;
int int_vec = svm->vmcb->control.exit_int_info & SVM_EVTINJ_VEC_MASK;

tss_selector = (u16)svm->vmcb->control.exit_info_1;

Expand All @@ -1843,8 +1844,14 @@ static int task_switch_interception(struct vcpu_svm *svm,
reason = TASK_SWITCH_CALL;


if (reason != TASK_SWITCH_GATE || int_type == SVM_EXITINTINFO_TYPE_SOFT)
skip_emulated_instruction(&svm->vcpu);
if (reason != TASK_SWITCH_GATE ||
int_type == SVM_EXITINTINFO_TYPE_SOFT ||
(int_type == SVM_EXITINTINFO_TYPE_EXEPT &&
(int_vec == OF_VECTOR || int_vec == BP_VECTOR))) {
if (emulate_instruction(&svm->vcpu, kvm_run, 0, 0,
EMULTYPE_SKIP) != EMULATE_DONE)
return 0;
}

return kvm_task_switch(&svm->vcpu, tss_selector, reason);
}
Expand Down

0 comments on commit 25be7b2

Please sign in to comment.