@@ -3045,6 +3045,7 @@ static void svm_intr_intercept_mix_if(void)
vmcb->save.rflags &= ~X86_EFLAGS_IF;
test_set_guest(svm_intr_intercept_mix_if_guest);
+ cli();
apic_icr_write(APIC_DEST_SELF | APIC_DEST_PHYSICAL | APIC_DM_FIXED | 0x55, 0);
svm_intr_intercept_mix_run_guest(&dummy_isr_recevied, SVM_EXIT_INTR);
}
@@ -3077,6 +3078,7 @@ static void svm_intr_intercept_mix_gif(void)
vmcb->save.rflags &= ~X86_EFLAGS_IF;
test_set_guest(svm_intr_intercept_mix_gif_guest);
+ cli();
apic_icr_write(APIC_DEST_SELF | APIC_DEST_PHYSICAL | APIC_DM_FIXED | 0x55, 0);
svm_intr_intercept_mix_run_guest(&dummy_isr_recevied, SVM_EXIT_INTR);
}
When injecting self IPI the test assumes that initial EFLAGS.IF flag is zero, but previous tests might have set it. Explicitly disable interrupts to avoid this assumption. Signed-off-by: Maxim Levitsky <mlevitsk@redhat.com> --- x86/svm_tests.c | 2 ++ 1 file changed, 2 insertions(+)