diff options
author | Marek Olšák <[email protected]> | 2014-01-22 02:02:18 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2014-01-28 01:39:42 +0100 |
commit | a4c218f398a6176f2ecbe7e295020d348670a957 (patch) | |
tree | da191a95391994e2c698c04451ff5d76c8277c17 /src/gallium/drivers/r600/r600_pipe.c | |
parent | ba0c16f7b2283db9dbeef036cf54dd6b694e4eaa (diff) |
r600g,radeonsi: consolidate variables for CS tracing
Reviewed-by: Michel Dänzer <[email protected]>
Reviewed-by: Tom Stellard <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600/r600_pipe.c')
-rw-r--r-- | src/gallium/drivers/r600/r600_pipe.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600/r600_pipe.c index a7138969d96..eec04bfaebb 100644 --- a/src/gallium/drivers/r600/r600_pipe.c +++ b/src/gallium/drivers/r600/r600_pipe.c @@ -259,8 +259,8 @@ static struct pipe_context *r600_create_context(struct pipe_screen *screen, void goto fail; } - if (rscreen->trace_bo) { - rctx->b.rings.gfx.cs = rctx->b.ws->cs_create(rctx->b.ws, RING_GFX, rscreen->trace_bo->cs_buf); + if (rscreen->b.trace_bo) { + rctx->b.rings.gfx.cs = rctx->b.ws->cs_create(rctx->b.ws, RING_GFX, rscreen->b.trace_bo->cs_buf); } else { rctx->b.rings.gfx.cs = rctx->b.ws->cs_create(rctx->b.ws, RING_GFX, NULL); } @@ -743,9 +743,9 @@ static void r600_destroy_screen(struct pipe_screen* pscreen) compute_memory_pool_delete(rscreen->global_pool); } - if (rscreen->trace_bo) { - rscreen->b.ws->buffer_unmap(rscreen->trace_bo->cs_buf); - pipe_resource_reference((struct pipe_resource**)&rscreen->trace_bo, NULL); + if (rscreen->b.trace_bo) { + rscreen->b.ws->buffer_unmap(rscreen->b.trace_bo->cs_buf); + pipe_resource_reference((struct pipe_resource**)&rscreen->b.trace_bo, NULL); } rscreen->b.ws->destroy(rscreen->b.ws); @@ -860,14 +860,14 @@ struct pipe_screen *r600_screen_create(struct radeon_winsys *ws) rscreen->global_pool = compute_memory_pool_new(rscreen); - rscreen->cs_count = 0; + rscreen->b.cs_count = 0; if (rscreen->b.info.drm_minor >= 28 && (rscreen->b.debug_flags & DBG_TRACE_CS)) { - rscreen->trace_bo = (struct r600_resource*)pipe_buffer_create(&rscreen->b.b, + rscreen->b.trace_bo = (struct r600_resource*)pipe_buffer_create(&rscreen->b.b, PIPE_BIND_CUSTOM, PIPE_USAGE_STAGING, 4096); - if (rscreen->trace_bo) { - rscreen->trace_ptr = rscreen->b.ws->buffer_map(rscreen->trace_bo->cs_buf, NULL, + if (rscreen->b.trace_bo) { + rscreen->b.trace_ptr = rscreen->b.ws->buffer_map(rscreen->b.trace_bo->cs_buf, NULL, PIPE_TRANSFER_UNSYNCHRONIZED); } } |