diff options
author | Marek Olšák <[email protected]> | 2017-12-31 22:51:14 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2018-02-17 04:52:17 +0100 |
commit | d790b6cecea7c5df5465e76ba63b6e7e9d6e1f5e (patch) | |
tree | 1bc7baf4e80540cd35c95cbee8b57ccf7476b16b /src/gallium | |
parent | 50581549b71c021838c39666b9d1ab517b61b2dd (diff) |
radeonsi: move const_uploader allocations to 32-bit address space
Reviewed-by: Samuel Pitoiset <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/radeon/r600_buffer_common.c | 3 | ||||
-rw-r--r-- | src/gallium/drivers/radeon/r600_pipe_common.c | 5 | ||||
-rw-r--r-- | src/gallium/drivers/radeon/r600_pipe_common.h | 1 |
3 files changed, 7 insertions, 2 deletions
diff --git a/src/gallium/drivers/radeon/r600_buffer_common.c b/src/gallium/drivers/radeon/r600_buffer_common.c index aca536d7fd4..2d64eed1c10 100644 --- a/src/gallium/drivers/radeon/r600_buffer_common.c +++ b/src/gallium/drivers/radeon/r600_buffer_common.c @@ -177,6 +177,9 @@ void si_init_resource_fields(struct si_screen *sscreen, if (res->b.b.flags & R600_RESOURCE_FLAG_READ_ONLY) res->flags |= RADEON_FLAG_READ_ONLY; + if (res->b.b.flags & R600_RESOURCE_FLAG_32BIT) + res->flags |= RADEON_FLAG_32BIT; + /* Set expected VRAM and GART usage for the buffer. */ res->vram_usage = 0; res->gart_usage = 0; diff --git a/src/gallium/drivers/radeon/r600_pipe_common.c b/src/gallium/drivers/radeon/r600_pipe_common.c index 9e45a9f0d1d..d46cb646519 100644 --- a/src/gallium/drivers/radeon/r600_pipe_common.c +++ b/src/gallium/drivers/radeon/r600_pipe_common.c @@ -452,8 +452,9 @@ bool si_common_context_init(struct r600_common_context *rctx, rctx->b.const_uploader = u_upload_create(&rctx->b, 128 * 1024, 0, PIPE_USAGE_DEFAULT, - sscreen->cpdma_prefetch_writes_memory ? - 0 : R600_RESOURCE_FLAG_READ_ONLY); + R600_RESOURCE_FLAG_32BIT | + (sscreen->cpdma_prefetch_writes_memory ? + 0 : R600_RESOURCE_FLAG_READ_ONLY)); if (!rctx->b.const_uploader) return false; diff --git a/src/gallium/drivers/radeon/r600_pipe_common.h b/src/gallium/drivers/radeon/r600_pipe_common.h index d82e123b081..4f3aa1fe3ce 100644 --- a/src/gallium/drivers/radeon/r600_pipe_common.h +++ b/src/gallium/drivers/radeon/r600_pipe_common.h @@ -54,6 +54,7 @@ struct si_context; #define R600_RESOURCE_FLAG_DISABLE_DCC (PIPE_RESOURCE_FLAG_DRV_PRIV << 3) #define R600_RESOURCE_FLAG_UNMAPPABLE (PIPE_RESOURCE_FLAG_DRV_PRIV << 4) #define R600_RESOURCE_FLAG_READ_ONLY (PIPE_RESOURCE_FLAG_DRV_PRIV << 5) +#define R600_RESOURCE_FLAG_32BIT (PIPE_RESOURCE_FLAG_DRV_PRIV << 6) /* Debug flags. */ enum { |