summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/svga
diff options
context:
space:
mode:
authorTimothy Arceri <[email protected]>2017-03-05 12:32:06 +1100
committerTimothy Arceri <[email protected]>2017-03-07 08:53:05 +1100
commit628e84a58fdb26c63a705861b92f65f242613321 (patch)
treebd6084a4dee53a1f180c62f41e790ab490ddf3ee /src/gallium/drivers/svga
parentba72554f3e576c1674d52ab16d8d2edff9398b71 (diff)
gallium/util: replace pipe_mutex_unlock() with mtx_unlock()
pipe_mutex_unlock() was made unnecessary with fd33a6bcd7f12. Replaced using: find ./src -type f -exec sed -i -- \ 's:pipe_mutex_unlock(\([^)]*\)):mtx_unlock(\&\1):g' {} \; Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/svga')
-rw-r--r--src/gallium/drivers/svga/svga_resource_buffer.c4
-rw-r--r--src/gallium/drivers/svga/svga_resource_buffer_upload.c4
-rw-r--r--src/gallium/drivers/svga/svga_sampler_view.c6
-rw-r--r--src/gallium/drivers/svga/svga_screen_cache.c10
4 files changed, 12 insertions, 12 deletions
diff --git a/src/gallium/drivers/svga/svga_resource_buffer.c b/src/gallium/drivers/svga/svga_resource_buffer.c
index 05e91cbfe5a..7808903083b 100644
--- a/src/gallium/drivers/svga/svga_resource_buffer.c
+++ b/src/gallium/drivers/svga/svga_resource_buffer.c
@@ -298,7 +298,7 @@ svga_buffer_transfer_flush_region( struct pipe_context *pipe,
mtx_lock(&ss->swc_mutex);
svga_buffer_add_range(sbuf, offset, offset + length);
- pipe_mutex_unlock(ss->swc_mutex);
+ mtx_unlock(&ss->swc_mutex);
}
@@ -339,7 +339,7 @@ svga_buffer_transfer_unmap( struct pipe_context *pipe,
}
}
- pipe_mutex_unlock(ss->swc_mutex);
+ mtx_unlock(&ss->swc_mutex);
FREE(transfer);
SVGA_STATS_TIME_POP(svga_sws(svga));
}
diff --git a/src/gallium/drivers/svga/svga_resource_buffer_upload.c b/src/gallium/drivers/svga/svga_resource_buffer_upload.c
index e41f47520e8..9d93b48fd36 100644
--- a/src/gallium/drivers/svga/svga_resource_buffer_upload.c
+++ b/src/gallium/drivers/svga/svga_resource_buffer_upload.c
@@ -646,7 +646,7 @@ svga_buffer_update_hw(struct svga_context *svga, struct svga_buffer *sbuf)
assert(map);
assert(!retry);
if (!map) {
- pipe_mutex_unlock(ss->swc_mutex);
+ mtx_unlock(&ss->swc_mutex);
svga_buffer_destroy_hw_storage(ss, sbuf);
return PIPE_ERROR;
}
@@ -670,7 +670,7 @@ svga_buffer_update_hw(struct svga_context *svga, struct svga_buffer *sbuf)
sbuf->swbuf = NULL;
}
- pipe_mutex_unlock(ss->swc_mutex);
+ mtx_unlock(&ss->swc_mutex);
}
return PIPE_OK;
diff --git a/src/gallium/drivers/svga/svga_sampler_view.c b/src/gallium/drivers/svga/svga_sampler_view.c
index 053cfc58ce5..ee4ef3ca7b0 100644
--- a/src/gallium/drivers/svga/svga_sampler_view.c
+++ b/src/gallium/drivers/svga/svga_sampler_view.c
@@ -96,13 +96,13 @@ svga_get_tex_sampler_view(struct pipe_context *pipe,
tex->cached_view->min_lod == min_lod &&
tex->cached_view->max_lod == max_lod) {
svga_sampler_view_reference(&sv, tex->cached_view);
- pipe_mutex_unlock(ss->tex_mutex);
+ mtx_unlock(&ss->tex_mutex);
SVGA_DBG(DEBUG_VIEWS, "svga: Sampler view: reuse %p, %u %u, last %u\n",
pt, min_lod, max_lod, pt->last_level);
svga_validate_sampler_view(svga_context(pipe), sv);
return sv;
}
- pipe_mutex_unlock(ss->tex_mutex);
+ mtx_unlock(&ss->tex_mutex);
}
sv = CALLOC_STRUCT(svga_sampler_view);
@@ -165,7 +165,7 @@ svga_get_tex_sampler_view(struct pipe_context *pipe,
mtx_lock(&ss->tex_mutex);
svga_sampler_view_reference(&tex->cached_view, sv);
- pipe_mutex_unlock(ss->tex_mutex);
+ mtx_unlock(&ss->tex_mutex);
debug_reference(&sv->reference,
(debug_reference_descriptor)
diff --git a/src/gallium/drivers/svga/svga_screen_cache.c b/src/gallium/drivers/svga/svga_screen_cache.c
index 55f9426217c..d26e79a5c4a 100644
--- a/src/gallium/drivers/svga/svga_screen_cache.c
+++ b/src/gallium/drivers/svga/svga_screen_cache.c
@@ -154,7 +154,7 @@ svga_screen_cache_lookup(struct svga_screen *svgascreen,
next = curr->next;
}
- pipe_mutex_unlock(cache->mutex);
+ mtx_unlock(&cache->mutex);
if (SVGA_DEBUG & DEBUG_DMA)
debug_printf("%s: cache %s after %u tries (bucket %d)\n", __FUNCTION__,
@@ -231,7 +231,7 @@ svga_screen_cache_add(struct svga_screen *svgascreen,
if (surf_size >= SVGA_HOST_SURFACE_CACHE_BYTES) {
/* this surface is too large to cache, just free it */
sws->surface_reference(sws, &handle, NULL);
- pipe_mutex_unlock(cache->mutex);
+ mtx_unlock(&cache->mutex);
return;
}
@@ -249,7 +249,7 @@ svga_screen_cache_add(struct svga_screen *svgascreen,
* just discard this surface.
*/
sws->surface_reference(sws, &handle, NULL);
- pipe_mutex_unlock(cache->mutex);
+ mtx_unlock(&cache->mutex);
return;
}
}
@@ -300,7 +300,7 @@ svga_screen_cache_add(struct svga_screen *svgascreen,
sws->surface_reference(sws, &handle, NULL);
}
- pipe_mutex_unlock(cache->mutex);
+ mtx_unlock(&cache->mutex);
}
@@ -368,7 +368,7 @@ svga_screen_cache_flush(struct svga_screen *svgascreen,
next = curr->next;
}
- pipe_mutex_unlock(cache->mutex);
+ mtx_unlock(&cache->mutex);
}