diff --git a/src/gallium/auxiliary/util/u_cpu_detect.c b/src/gallium/auxiliary/util/u_cpu_detect.c index 6a59f271a83..3c6ae4ea1a3 100644 --- a/src/gallium/auxiliary/util/u_cpu_detect.c +++ b/src/gallium/auxiliary/util/u_cpu_detect.c @@ -374,7 +374,7 @@ util_cpu_detect(void) } #elif defined(PIPE_OS_UNIX) && defined(_SC_NPROCESSORS_ONLN) util_cpu_caps.nr_cpus = sysconf(_SC_NPROCESSORS_ONLN); - if (util_cpu_caps.nr_cpus == ~0u) + if (util_cpu_caps.nr_cpus == ~0) util_cpu_caps.nr_cpus = 1; #elif defined(PIPE_OS_BSD) { diff --git a/src/gallium/auxiliary/util/u_hash_table.c b/src/gallium/auxiliary/util/u_hash_table.c index 77fa477e33a..201b9a23b65 100644 --- a/src/gallium/auxiliary/util/u_hash_table.c +++ b/src/gallium/auxiliary/util/u_hash_table.c @@ -271,7 +271,7 @@ util_hash_table_foreach(struct util_hash_table *ht, static enum pipe_error -util_hash_inc(void *k, void *v, void *d) +util_hash_inc(UNUSED void *k, UNUSED void *v, void *d) { ++*(size_t *)d; return PIPE_OK; diff --git a/src/gallium/auxiliary/util/u_tests.c b/src/gallium/auxiliary/util/u_tests.c index 293a4580a9f..bae3fa111a4 100644 --- a/src/gallium/auxiliary/util/u_tests.c +++ b/src/gallium/auxiliary/util/u_tests.c @@ -649,7 +649,7 @@ test_texture_barrier(struct pipe_context *ctx, bool use_fbfetch, /* Vertex shader. */ void *vs = util_set_passthrough_vertex_shader(cso, ctx, false); - for (int i = 0; i < num_samples / 2; i++) { + for (unsigned i = 0; i < num_samples / 2; i++) { float value; /* 2 consecutive samples should have the same color to test MSAA