diff options
author | Marek Olšák <[email protected]> | 2017-02-15 18:49:11 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2017-02-18 01:22:08 +0100 |
commit | a550fbb510c998a0e484e9bf996e2d884ce3230e (patch) | |
tree | 56d620dd938e84e4e533863fe4d6a541dee619fb /src/gallium/drivers/radeon | |
parent | 791e8ce04a7e9970f437858bdff0a1f8b47626ba (diff) |
gallium/radeon: use TCC line size as alignment in other places
Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeon')
-rw-r--r-- | src/gallium/drivers/radeon/r600_buffer_common.c | 3 | ||||
-rw-r--r-- | src/gallium/drivers/radeon/r600_pipe_common.c | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/gallium/drivers/radeon/r600_buffer_common.c b/src/gallium/drivers/radeon/r600_buffer_common.c index 9e5a8a6dff8..e37e36f3b45 100644 --- a/src/gallium/drivers/radeon/r600_buffer_common.c +++ b/src/gallium/drivers/radeon/r600_buffer_common.c @@ -369,7 +369,8 @@ static void *r600_buffer_transfer_map(struct pipe_context *ctx, u_upload_alloc(ctx->stream_uploader, 0, box->width + (box->x % R600_MAP_BUFFER_ALIGNMENT), - 256, &offset, (struct pipe_resource**)&staging, + rctx->screen->info.tcc_cache_line_size, + &offset, (struct pipe_resource**)&staging, (void**)&data); if (staging) { diff --git a/src/gallium/drivers/radeon/r600_pipe_common.c b/src/gallium/drivers/radeon/r600_pipe_common.c index 8405c5e80f9..d573b39d7c0 100644 --- a/src/gallium/drivers/radeon/r600_pipe_common.c +++ b/src/gallium/drivers/radeon/r600_pipe_common.c @@ -193,7 +193,8 @@ void r600_draw_rectangle(struct blitter_context *blitter, /* Upload vertices. The hw rectangle has only 3 vertices, * I guess the 4th one is derived from the first 3. * The vertex specification should match u_blitter's vertex element state. */ - u_upload_alloc(rctx->b.stream_uploader, 0, sizeof(float) * 24, 256, + u_upload_alloc(rctx->b.stream_uploader, 0, sizeof(float) * 24, + rctx->screen->info.tcc_cache_line_size, &offset, &buf, (void**)&vb); if (!buf) return; |