mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-26 23:00:34 +01:00
asahi: do not stall for writers with invalid mips
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26963>
This commit is contained in:
parent
69e6606bf9
commit
c9b2bf84e5
1 changed files with 7 additions and 0 deletions
|
|
@ -762,6 +762,13 @@ agx_prepare_for_map(struct agx_context *ctx, struct agx_resource *rsrc,
|
|||
if (staging_blit)
|
||||
return;
|
||||
|
||||
/* If the level has not been written, we may freely do CPU access (writes),
|
||||
* even if other levels are being written by the GPU. This lets us write some
|
||||
* mip levels on the CPU and some on the GPU, without stalling.
|
||||
*/
|
||||
if (!agx_resource_valid(rsrc, level))
|
||||
return;
|
||||
|
||||
/* Upgrade DISCARD_RANGE to WHOLE_RESOURCE if the whole resource is
|
||||
* being mapped.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue