From: Avi Kivity Subject: [PATCH 1/4] KVM: Initialize operand and address sizes before emulating interrupts Date: Tue, 17 Aug 2010 11:26:40 +0300 Message-ID: <1282033603-25938-2-git-send-email-avi@redhat.com> References: <1282033603-25938-1-git-send-email-avi@redhat.com> To: kvm@vger.kernel.org, Marcelo Tosatti , Mohammed Gamal Return-path: Received: from mx1.redhat.com ([209.132.183.28]:41840 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752199Ab0HQI0q (ORCPT ); Tue, 17 Aug 2010 04:26:46 -0400 In-Reply-To: <1282033603-25938-1-git-send-email-avi@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: The emulator needs the operand and address sizes to be valid. Signed-off-by: Avi Kivity --- arch/x86/kvm/x86.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index 6a77fa1..f6a31a1 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -3965,6 +3965,8 @@ int kvm_inject_realmode_interrupt(struct kvm_vcpu *vcpu, int irq) init_emulate_ctxt(vcpu); + vcpu->arch.emulate_ctxt.decode.op_bytes = 2; + vcpu->arch.emulate_ctxt.decode.ad_bytes = 2; ret = emulate_int_real(&vcpu->arch.emulate_ctxt, &emulate_ops, irq); if (ret != X86EMUL_CONTINUE) -- 1.7.1