aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kvm/svm.c1
-rw-r--r--arch/x86/kvm/vmx.c1
-rw-r--r--arch/x86/kvm/x86.c2
-rw-r--r--arch/x86/kvm/x86_emulate.c2
4 files changed, 3 insertions, 3 deletions
diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c
index 743aebd7bfcc..f0ad4d4217e4 100644
--- a/arch/x86/kvm/svm.c
+++ b/arch/x86/kvm/svm.c
@@ -1115,6 +1115,7 @@ static int io_interception(struct vcpu_svm *svm, struct kvm_run *kvm_run)
1115 rep = (io_info & SVM_IOIO_REP_MASK) != 0; 1115 rep = (io_info & SVM_IOIO_REP_MASK) != 0;
1116 down = (svm->vmcb->save.rflags & X86_EFLAGS_DF) != 0; 1116 down = (svm->vmcb->save.rflags & X86_EFLAGS_DF) != 0;
1117 1117
1118 skip_emulated_instruction(&svm->vcpu);
1118 return kvm_emulate_pio(&svm->vcpu, kvm_run, in, size, port); 1119 return kvm_emulate_pio(&svm->vcpu, kvm_run, in, size, port);
1119} 1120}
1120 1121
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 7623eb7b68d5..816d23185fb8 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -2687,6 +2687,7 @@ static int handle_io(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)
2687 rep = (exit_qualification & 32) != 0; 2687 rep = (exit_qualification & 32) != 0;
2688 port = exit_qualification >> 16; 2688 port = exit_qualification >> 16;
2689 2689
2690 skip_emulated_instruction(vcpu);
2690 return kvm_emulate_pio(vcpu, kvm_run, in, size, port); 2691 return kvm_emulate_pio(vcpu, kvm_run, in, size, port);
2691} 2692}
2692 2693
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index ceeac8897143..38f79b6aaf1e 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -2478,8 +2478,6 @@ int kvm_emulate_pio(struct kvm_vcpu *vcpu, struct kvm_run *run, int in,
2478 val = kvm_register_read(vcpu, VCPU_REGS_RAX); 2478 val = kvm_register_read(vcpu, VCPU_REGS_RAX);
2479 memcpy(vcpu->arch.pio_data, &val, 4); 2479 memcpy(vcpu->arch.pio_data, &val, 4);
2480 2480
2481 kvm_x86_ops->skip_emulated_instruction(vcpu);
2482
2483 pio_dev = vcpu_find_pio_dev(vcpu, port, size, !in); 2481 pio_dev = vcpu_find_pio_dev(vcpu, port, size, !in);
2484 if (pio_dev) { 2482 if (pio_dev) {
2485 kernel_pio(pio_dev, vcpu, vcpu->arch.pio_data); 2483 kernel_pio(pio_dev, vcpu, vcpu->arch.pio_data);
diff --git a/arch/x86/kvm/x86_emulate.c b/arch/x86/kvm/x86_emulate.c
index 57d7cc45be44..8f60ace13874 100644
--- a/arch/x86/kvm/x86_emulate.c
+++ b/arch/x86/kvm/x86_emulate.c
@@ -1772,7 +1772,7 @@ special_insn:
1772 c->eip = saved_eip; 1772 c->eip = saved_eip;
1773 goto cannot_emulate; 1773 goto cannot_emulate;
1774 } 1774 }
1775 return 0; 1775 break;
1776 case 0xf4: /* hlt */ 1776 case 0xf4: /* hlt */
1777 ctxt->vcpu->arch.halt_request = 1; 1777 ctxt->vcpu->arch.halt_request = 1;
1778 break; 1778 break;