From bb84fa146f2252f22999205a2904d8a948bffd3b Mon Sep 17 00:00:00 2001 From: Eric Engestrom Date: Sat, 20 Oct 2018 18:00:08 +0100 Subject: util: use C99 declaration in the for-loop hash_table_foreach() macro Signed-off-by: Eric Engestrom Reviewed-by: Timothy Arceri --- src/gallium/drivers/v3d/v3d_context.c | 1 - src/gallium/drivers/v3d/v3d_job.c | 6 ------ src/gallium/drivers/v3d/v3d_program.c | 2 -- 3 files changed, 9 deletions(-) (limited to 'src/gallium/drivers/v3d') diff --git a/src/gallium/drivers/v3d/v3d_context.c b/src/gallium/drivers/v3d/v3d_context.c index 2fd2fa0bbf3..12741b578e3 100644 --- a/src/gallium/drivers/v3d/v3d_context.c +++ b/src/gallium/drivers/v3d/v3d_context.c @@ -43,7 +43,6 @@ v3d_flush(struct pipe_context *pctx) { struct v3d_context *v3d = v3d_context(pctx); - struct hash_entry *entry; hash_table_foreach(v3d->jobs, entry) { struct v3d_job *job = entry->data; v3d_job_submit(v3d, job); diff --git a/src/gallium/drivers/v3d/v3d_job.c b/src/gallium/drivers/v3d/v3d_job.c index 3645305f4f0..8ba5c8996dc 100644 --- a/src/gallium/drivers/v3d/v3d_job.c +++ b/src/gallium/drivers/v3d/v3d_job.c @@ -47,8 +47,6 @@ remove_from_ht(struct hash_table *ht, void *key) static void v3d_job_free(struct v3d_context *v3d, struct v3d_job *job) { - struct set_entry *entry; - set_foreach(job->bos, entry) { struct v3d_bo *bo = (struct v3d_bo *)entry->key; v3d_bo_unreference(&bo); @@ -57,8 +55,6 @@ v3d_job_free(struct v3d_context *v3d, struct v3d_job *job) remove_from_ht(v3d->jobs, &job->key); if (job->write_prscs) { - struct set_entry *entry; - set_foreach(job->write_prscs, entry) { const struct pipe_resource *prsc = entry->key; @@ -175,7 +171,6 @@ v3d_flush_jobs_reading_resource(struct v3d_context *v3d, v3d_flush_jobs_writing_resource(v3d, prsc); - struct hash_entry *entry; hash_table_foreach(v3d->jobs, entry) { struct v3d_job *job = entry->data; @@ -351,7 +346,6 @@ v3d_clif_dump(struct v3d_context *v3d, struct v3d_job *job) stderr, V3D_DEBUG & V3D_DEBUG_CL); - struct set_entry *entry; set_foreach(job->bos, entry) { struct v3d_bo *bo = (void *)entry->key; char *name = ralloc_asprintf(NULL, "%s_0x%x", diff --git a/src/gallium/drivers/v3d/v3d_program.c b/src/gallium/drivers/v3d/v3d_program.c index e9fae77d5c0..1d4b0bb2080 100644 --- a/src/gallium/drivers/v3d/v3d_program.c +++ b/src/gallium/drivers/v3d/v3d_program.c @@ -618,7 +618,6 @@ v3d_shader_state_delete(struct pipe_context *pctx, void *hwcso) struct v3d_context *v3d = v3d_context(pctx); struct v3d_uncompiled_shader *so = hwcso; - struct hash_entry *entry; hash_table_foreach(v3d->fs_cache, entry) { delete_from_cache_if_matches(v3d->fs_cache, &v3d->prog.fs, entry, so); @@ -673,7 +672,6 @@ v3d_program_fini(struct pipe_context *pctx) { struct v3d_context *v3d = v3d_context(pctx); - struct hash_entry *entry; hash_table_foreach(v3d->fs_cache, entry) { struct v3d_compiled_shader *shader = entry->data; v3d_bo_unreference(&shader->bo); -- cgit v1.2.3