[PATCH libdrm 03/17] intel: resolve shadowing warnings
Emil Velikov
emil.l.velikov at gmail.com
Mon Aug 24 09:34:06 PDT 2015
Cc: intel-gfx at lists.freedesktop.org
Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
---
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;
}
/**
--
2.5.0
More information about the dri-devel
mailing list