|
@@ -4599,7 +4599,7 @@ int x86_emulate_insn(struct x86_emulate_ctxt *ctxt)
|
|
fetch_possible_mmx_operand(ctxt, &ctxt->dst);
|
|
fetch_possible_mmx_operand(ctxt, &ctxt->dst);
|
|
}
|
|
}
|
|
|
|
|
|
- if (unlikely(ctxt->guest_mode) && ctxt->intercept) {
|
|
|
|
|
|
+ if (unlikely(ctxt->guest_mode) && (ctxt->d & Intercept)) {
|
|
rc = emulator_check_intercept(ctxt, ctxt->intercept,
|
|
rc = emulator_check_intercept(ctxt, ctxt->intercept,
|
|
X86_ICPT_PRE_EXCEPT);
|
|
X86_ICPT_PRE_EXCEPT);
|
|
if (rc != X86EMUL_CONTINUE)
|
|
if (rc != X86EMUL_CONTINUE)
|
|
@@ -4619,13 +4619,13 @@ int x86_emulate_insn(struct x86_emulate_ctxt *ctxt)
|
|
}
|
|
}
|
|
|
|
|
|
/* Do instruction specific permission checks */
|
|
/* Do instruction specific permission checks */
|
|
- if (ctxt->check_perm) {
|
|
|
|
|
|
+ if (ctxt->d & CheckPerm) {
|
|
rc = ctxt->check_perm(ctxt);
|
|
rc = ctxt->check_perm(ctxt);
|
|
if (rc != X86EMUL_CONTINUE)
|
|
if (rc != X86EMUL_CONTINUE)
|
|
goto done;
|
|
goto done;
|
|
}
|
|
}
|
|
|
|
|
|
- if (unlikely(ctxt->guest_mode) && ctxt->intercept) {
|
|
|
|
|
|
+ if (unlikely(ctxt->guest_mode) && (ctxt->d & Intercept)) {
|
|
rc = emulator_check_intercept(ctxt, ctxt->intercept,
|
|
rc = emulator_check_intercept(ctxt, ctxt->intercept,
|
|
X86_ICPT_POST_EXCEPT);
|
|
X86_ICPT_POST_EXCEPT);
|
|
if (rc != X86EMUL_CONTINUE)
|
|
if (rc != X86EMUL_CONTINUE)
|
|
@@ -4671,7 +4671,7 @@ int x86_emulate_insn(struct x86_emulate_ctxt *ctxt)
|
|
|
|
|
|
special_insn:
|
|
special_insn:
|
|
|
|
|
|
- if (unlikely(ctxt->guest_mode) && ctxt->intercept) {
|
|
|
|
|
|
+ if (unlikely(ctxt->guest_mode) && (ctxt->d & Intercept)) {
|
|
rc = emulator_check_intercept(ctxt, ctxt->intercept,
|
|
rc = emulator_check_intercept(ctxt, ctxt->intercept,
|
|
X86_ICPT_POST_MEMACCESS);
|
|
X86_ICPT_POST_MEMACCESS);
|
|
if (rc != X86EMUL_CONTINUE)
|
|
if (rc != X86EMUL_CONTINUE)
|