From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: [PATCH 3/7] KVM: x86 emulator: drop dead pf injection in emulate_popf() Date: Mon, 22 Nov 2010 17:53:23 +0200 Message-ID: <1290441207-4250-4-git-send-email-avi@redhat.com> References: <1290441207-4250-1-git-send-email-avi@redhat.com> To: Marcelo Tosatti , kvm@vger.kernel.org Return-path: Received: from mx1.redhat.com ([209.132.183.28]:33276 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752594Ab0KVPxl (ORCPT ); Mon, 22 Nov 2010 10:53:41 -0500 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id oAMFrfCd021318 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 22 Nov 2010 10:53:41 -0500 Received: from cleopatra.tlv.redhat.com (cleopatra.tlv.redhat.com [10.35.255.11]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id oAMFrddm022101 for ; Mon, 22 Nov 2010 10:53:41 -0500 In-Reply-To: <1290441207-4250-1-git-send-email-avi@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: If rc == X86EMUL_PROPAGATE_FAULT, we would have returned earlier. Signed-off-by: Avi Kivity --- arch/x86/kvm/emulate.c | 8 -------- 1 files changed, 0 insertions(+), 8 deletions(-) diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c index 68d72db..b39df7b 100644 --- a/arch/x86/kvm/emulate.c +++ b/arch/x86/kvm/emulate.c @@ -479,11 +479,6 @@ static void emulate_gp(struct x86_emulate_ctxt *ctxt, int err) emulate_exception(ctxt, GP_VECTOR, err, true); } -static void emulate_pf(struct x86_emulate_ctxt *ctxt) -{ - emulate_exception(ctxt, PF_VECTOR, 0, true); -} - static void emulate_ud(struct x86_emulate_ctxt *ctxt) { emulate_exception(ctxt, UD_VECTOR, 0, false); @@ -1184,9 +1179,6 @@ static int emulate_popf(struct x86_emulate_ctxt *ctxt, *(unsigned long *)dest = (ctxt->eflags & ~change_mask) | (val & change_mask); - if (rc == X86EMUL_PROPAGATE_FAULT) - emulate_pf(ctxt); - return rc; } -- 1.7.1