radeonsi: fix typo in sdma code
cs_create returns a bool not an int so check correctly for success (sdma was still used because sdma_cs would be non NULL when entering this function the second time). While at it update debug_flags to not retry creating sdma_cs if it failed. Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35582>
This commit is contained in:
committed by
Marge Bot
parent
6c206ffbbc
commit
5da4941101
@@ -405,8 +405,10 @@ bool si_sdma_copy_image(struct si_context *sctx, struct si_texture *dst, struct
|
||||
return false;
|
||||
|
||||
sctx->sdma_cs = CALLOC_STRUCT(radeon_cmdbuf);
|
||||
if (ws->cs_create(sctx->sdma_cs, sctx->ctx, AMD_IP_SDMA, NULL, NULL))
|
||||
if (!ws->cs_create(sctx->sdma_cs, sctx->ctx, AMD_IP_SDMA, NULL, NULL)) {
|
||||
sctx->screen->debug_flags |= DBG(NO_DMA);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (!si_prepare_for_sdma_copy(sctx, dst, src))
|
||||
|
||||
Reference in New Issue
Block a user