summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeon/r600_query.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2016-06-21 21:13:00 +0200
committerMarek Olšák <[email protected]>2016-06-25 23:13:42 +0200
commitd5383a7d3114aa5f81a704ff84f58de6b41f94bd (patch)
tree77fcb982312396216e5e3edabaaa2c5a7669e5db /src/gallium/drivers/radeon/r600_query.c
parent81978c6febd43b8a88a4db09133f9659e15b492c (diff)
gallium/radeon: use r600_resource_reference
Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Vedran Miletić <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeon/r600_query.c')
-rw-r--r--src/gallium/drivers/radeon/r600_query.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gallium/drivers/radeon/r600_query.c b/src/gallium/drivers/radeon/r600_query.c
index 2e06746b9ef..5474dbf2dea 100644
--- a/src/gallium/drivers/radeon/r600_query.c
+++ b/src/gallium/drivers/radeon/r600_query.c
@@ -275,11 +275,11 @@ void r600_query_hw_destroy(struct r600_common_context *rctx,
while (prev) {
struct r600_query_buffer *qbuf = prev;
prev = prev->previous;
- pipe_resource_reference((struct pipe_resource**)&qbuf->buf, NULL);
+ r600_resource_reference(&qbuf->buf, NULL);
FREE(qbuf);
}
- pipe_resource_reference((struct pipe_resource**)&query->buffer.buf, NULL);
+ r600_resource_reference(&query->buffer.buf, NULL);
FREE(rquery);
}
@@ -301,7 +301,7 @@ static struct r600_resource *r600_new_query_buffer(struct r600_common_context *c
if (query->flags & R600_QUERY_HW_FLAG_PREDICATE) {
if (!query->ops->prepare_buffer(ctx, query, buf)) {
- pipe_resource_reference((struct pipe_resource **)&buf, NULL);
+ r600_resource_reference(&buf, NULL);
return NULL;
}
}
@@ -733,7 +733,7 @@ static void r600_query_hw_reset_buffers(struct r600_common_context *rctx,
while (prev) {
struct r600_query_buffer *qbuf = prev;
prev = prev->previous;
- pipe_resource_reference((struct pipe_resource**)&qbuf->buf, NULL);
+ r600_resource_reference(&qbuf->buf, NULL);
FREE(qbuf);
}
@@ -744,11 +744,11 @@ static void r600_query_hw_reset_buffers(struct r600_common_context *rctx,
/* Obtain a new buffer if the current one can't be mapped without a stall. */
if (r600_rings_is_buffer_referenced(rctx, query->buffer.buf->buf, RADEON_USAGE_READWRITE) ||
!rctx->ws->buffer_wait(query->buffer.buf->buf, 0, RADEON_USAGE_READWRITE)) {
- pipe_resource_reference((struct pipe_resource**)&query->buffer.buf, NULL);
+ r600_resource_reference(&query->buffer.buf, NULL);
query->buffer.buf = r600_new_query_buffer(rctx, query);
} else {
if (!query->ops->prepare_buffer(rctx, query, query->buffer.buf))
- pipe_resource_reference((struct pipe_resource**)&query->buffer.buf, NULL);
+ r600_resource_reference(&query->buffer.buf, NULL);
}
}
}
@@ -1132,7 +1132,7 @@ void r600_query_init_backend_mask(struct r600_common_context *ctx)
}
}
- pipe_resource_reference((struct pipe_resource**)&buffer, NULL);
+ r600_resource_reference(&buffer, NULL);
if (mask != 0) {
ctx->backend_mask = mask;