From patchwork Mon Aug 24 16:34:06 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Emil Velikov X-Patchwork-Id: 7065521 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 068D5C05AC for ; Mon, 24 Aug 2015 16:30:14 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 03E502078A for ; Mon, 24 Aug 2015 16:30:13 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 2A1D420784 for ; Mon, 24 Aug 2015 16:30:12 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3CC106E9EE; Mon, 24 Aug 2015 09:30:09 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wi0-f179.google.com (mail-wi0-f179.google.com [209.85.212.179]) by gabe.freedesktop.org (Postfix) with ESMTPS id 91B656E9EA; Mon, 24 Aug 2015 09:30:07 -0700 (PDT) Received: by widdq5 with SMTP id dq5so55574591wid.1; Mon, 24 Aug 2015 09:30:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=XkG3ulv7q6D30yxFwFmmzDdiNs4tWjVSAMTHIDCL0bs=; b=BAplCU3TtKcHclGGgz7RgDJHNyA6+25KAN1+NbmpNKVidK+dtgDN0AQOZdtK1zKmRy qMWc//rH9pryYjxLVfkZfHas3z2hc9ajIXR1m/GUxGBNN0iyu1Li9dkGTMVQwaCVt/3u MqOajhpl3r29ctWc3Mg6Zgnv0VGS/HnS4uaqNugmmFXb232NTozv8yrppyr9Zdq4030Y KmhEnt1Kgdsd36L51IUSfIiJdD4mhplGtriwajYLLwjVXYqB2quh2zrwgWOQgXb9dzUU sFbGyYa9ddCCezL7U3Y7mQsZ6c4VcqU+FZ5w1AprKxYJZZleOGHClrsTYUaXYsM8As3F kZDA== X-Received: by 10.180.97.41 with SMTP id dx9mr30855258wib.34.1440433805968; Mon, 24 Aug 2015 09:30:05 -0700 (PDT) Received: from arch-x220.localdomain (cpc12-croy20-2-0-cust52.croy.cable.virginm.net. [82.44.54.53]) by smtp.gmail.com with ESMTPSA id ll1sm16885984wic.14.2015.08.24.09.30.04 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 24 Aug 2015 09:30:05 -0700 (PDT) From: Emil Velikov To: dri-devel@lists.freedesktop.org Subject: [PATCH libdrm 03/17] intel: resolve shadowing warnings Date: Mon, 24 Aug 2015 17:34:06 +0100 Message-Id: <1440434060-31347-3-git-send-email-emil.l.velikov@gmail.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1440434060-31347-1-git-send-email-emil.l.velikov@gmail.com> References: <1440434060-31347-1-git-send-email-emil.l.velikov@gmail.com> Cc: intel-gfx@lists.freedesktop.org, emil.l.velikov@gmail.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Cc: intel-gfx@lists.freedesktop.org Signed-off-by: Emil Velikov --- intel/intel_bufmgr_fake.c | 2 +- intel/intel_bufmgr_gem.c | 7 +++---- intel/intel_decode.c | 7 ++----- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/intel/intel_bufmgr_fake.c b/intel/intel_bufmgr_fake.c index 75387b7..551e05d 100644 --- a/intel/intel_bufmgr_fake.c +++ b/intel/intel_bufmgr_fake.c @@ -1460,7 +1460,7 @@ restart: assert(ret == 0); if (bufmgr_fake->exec != NULL) { - int ret = bufmgr_fake->exec(bo, used, bufmgr_fake->exec_priv); + ret = bufmgr_fake->exec(bo, used, bufmgr_fake->exec_priv); if (ret != 0) { pthread_mutex_unlock(&bufmgr_fake->lock); return ret; diff --git a/intel/intel_bufmgr_gem.c b/intel/intel_bufmgr_gem.c index 2723e21..cf55a53 100644 --- a/intel/intel_bufmgr_gem.c +++ b/intel/intel_bufmgr_gem.c @@ -2165,8 +2165,7 @@ drm_intel_gem_bo_exec(drm_intel_bo *bo, int used, drm_intel_gem_dump_validation_list(bufmgr_gem); for (i = 0; i < bufmgr_gem->exec_count; i++) { - drm_intel_bo *bo = bufmgr_gem->exec_bos[i]; - drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; + bo_gem = (drm_intel_bo_gem *) bufmgr_gem->exec_bos[i]; bo_gem->idle = false; @@ -2186,6 +2185,7 @@ do_exec2(drm_intel_bo *bo, int used, drm_intel_context *ctx, unsigned int flags) { drm_intel_bufmgr_gem *bufmgr_gem = (drm_intel_bufmgr_gem *)bo->bufmgr; + drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *) bo; struct drm_i915_gem_execbuffer2 execbuf; int ret = 0; int i; @@ -2260,8 +2260,7 @@ skip_execution: drm_intel_gem_dump_validation_list(bufmgr_gem); for (i = 0; i < bufmgr_gem->exec_count; i++) { - drm_intel_bo *bo = bufmgr_gem->exec_bos[i]; - drm_intel_bo_gem *bo_gem = (drm_intel_bo_gem *)bo; + bo_gem = (drm_intel_bo_gem *) bufmgr_gem->exec_bos[i]; bo_gem->idle = false; diff --git a/intel/intel_decode.c b/intel/intel_decode.c index 2b902a3..345d457 100644 --- a/intel/intel_decode.c +++ b/intel/intel_decode.c @@ -3630,7 +3630,6 @@ decode_3d_965(struct drm_intel_decode *ctx) case 0x7a00: if (IS_GEN6(devid) || IS_GEN7(devid)) { - unsigned int i; if (len != 4 && len != 5) fprintf(out, "Bad count in PIPE_CONTROL\n"); @@ -3732,8 +3731,6 @@ decode_3d_965(struct drm_intel_decode *ctx) if (opcode_3d->func) { return opcode_3d->func(ctx); } else { - unsigned int i; - instr_out(ctx, 0, "%s\n", opcode_3d->name); for (i = 1; i < len; i++) { @@ -3883,9 +3880,9 @@ drm_intel_decode_set_head_tail(struct drm_intel_decode *ctx, void drm_intel_decode_set_output_file(struct drm_intel_decode *ctx, - FILE *out) + FILE *output) { - ctx->out = out; + ctx->out = output; } /**