From patchwork Sun May 1 17:25:07 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Takuya Yoshikawa X-Patchwork-Id: 746222 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.3) with ESMTP id p41HPGGg006262 for ; Sun, 1 May 2011 17:25:16 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755388Ab1EARZM (ORCPT ); Sun, 1 May 2011 13:25:12 -0400 Received: from mail-pz0-f46.google.com ([209.85.210.46]:39158 "EHLO mail-pz0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753305Ab1EARZL (ORCPT ); Sun, 1 May 2011 13:25:11 -0400 Received: by pzk9 with SMTP id 9so2770694pzk.19 for ; Sun, 01 May 2011 10:25:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:date:from:to:cc:subject:message-id:in-reply-to :references:x-mailer:mime-version:content-type :content-transfer-encoding; bh=TYZWmIfAueNegfVx82Af/hRNCUDI9rxBv+vBnQy0UhU=; b=EqG9GizFriyQAZBnXllP5kmJrMsCGSqPMpZxyehJ2MYBpPwf2cEdcsmsgC+TnLKba3 cRss09HqUXSsuYagSHtHT/r7UlpOiaX8XPceZ9Zht9stGsW6pwsCRoO7k41QC5ITw12P bm5J5cj8CpBJnZc51DEsnFc3ZmQCvE+eqgOg4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:in-reply-to:references:x-mailer :mime-version:content-type:content-transfer-encoding; b=WRcHBGrNgPjMYF0LDKWVOeJcyX5/uE5/xQiS7LMmiG1QfN7NV10rgondOV/MK7+pw7 1RF1o/weRhdpmtkjntkS5v2QwAzxFkWQQilDI1x05JLiX7XYaXZHM/Lw5PL9XsRwpNbp 8L+xKCod94yef/rEYa6dcuOgIz4RC4J4rgO+g= Received: by 10.68.29.100 with SMTP id j4mr8036673pbh.197.1304270711080; Sun, 01 May 2011 10:25:11 -0700 (PDT) Received: from amd (s198099.dynamic.ppp.asahi-net.or.jp [220.157.198.99]) by mx.google.com with ESMTPS id h4sm3269202pbj.2.2011.05.01.10.25.08 (version=SSLv3 cipher=OTHER); Sun, 01 May 2011 10:25:10 -0700 (PDT) Date: Mon, 2 May 2011 02:25:07 +0900 From: Takuya Yoshikawa To: avi@redhat.com, mtosatti@redhat.com Cc: kvm@vger.kernel.org, yoshikawa.takuya@oss.ntt.co.jp Subject: [PATCH 2/6] KVM: x86 emulator: Remove unused opt from read_descriptor() Message-Id: <20110502022507.4b5bd769.takuya.yoshikawa@gmail.com> In-Reply-To: <20110502022143.0ef5d756.takuya.yoshikawa@gmail.com> References: <20110502022143.0ef5d756.takuya.yoshikawa@gmail.com> X-Mailer: Sylpheed 3.1.0beta2 (GTK+ 2.22.0; x86_64-pc-linux-gnu) Mime-Version: 1.0 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Sun, 01 May 2011 17:25:16 +0000 (UTC) From: Takuya Yoshikawa Signed-off-by: Takuya Yoshikawa --- arch/x86/kvm/emulate.c | 8 +++----- 1 files changed, 3 insertions(+), 5 deletions(-) diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c index 1545092..72b268e 100644 --- a/arch/x86/kvm/emulate.c +++ b/arch/x86/kvm/emulate.c @@ -729,7 +729,6 @@ static void *decode_register(u8 modrm_reg, unsigned long *regs, } static int read_descriptor(struct x86_emulate_ctxt *ctxt, - struct x86_emulate_ops *ops, struct segmented_address addr, u16 *size, unsigned long *address, int op_bytes) { @@ -2720,7 +2719,7 @@ static int em_lgdt(struct x86_emulate_ctxt *ctxt) struct desc_ptr desc_ptr; int rc; - rc = read_descriptor(ctxt, ctxt->ops, c->src.addr.mem, + rc = read_descriptor(ctxt, c->src.addr.mem, &desc_ptr.size, &desc_ptr.address, c->op_bytes); if (rc != X86EMUL_CONTINUE) @@ -2749,9 +2748,8 @@ static int em_lidt(struct x86_emulate_ctxt *ctxt) struct desc_ptr desc_ptr; int rc; - rc = read_descriptor(ctxt, ctxt->ops, c->src.addr.mem, - &desc_ptr.size, - &desc_ptr.address, + rc = read_descriptor(ctxt, c->src.addr.mem, + &desc_ptr.size, &desc_ptr.address, c->op_bytes); if (rc != X86EMUL_CONTINUE) return rc;