mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 22:38:05 +02:00
radeonsi: make const and stream uploaders allocate read-only memory
and anything that clones these uploaders, like u_threaded_context. Tested-by: Dieter Nützel <Dieter@nuetzel-hh.de> Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
This commit is contained in:
parent
7a6643fb4c
commit
4038db72d4
1 changed files with 5 additions and 2 deletions
|
|
@ -445,12 +445,15 @@ bool si_common_context_init(struct r600_common_context *rctx,
|
|||
return false;
|
||||
|
||||
rctx->b.stream_uploader = u_upload_create(&rctx->b, 1024 * 1024,
|
||||
0, PIPE_USAGE_STREAM, 0);
|
||||
0, PIPE_USAGE_STREAM,
|
||||
R600_RESOURCE_FLAG_READ_ONLY);
|
||||
if (!rctx->b.stream_uploader)
|
||||
return false;
|
||||
|
||||
rctx->b.const_uploader = u_upload_create(&rctx->b, 128 * 1024,
|
||||
0, PIPE_USAGE_DEFAULT, 0);
|
||||
0, PIPE_USAGE_DEFAULT,
|
||||
sscreen->cpdma_prefetch_writes_memory ?
|
||||
0 : R600_RESOURCE_FLAG_READ_ONLY);
|
||||
if (!rctx->b.const_uploader)
|
||||
return false;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue