panfrost: Assert staging resource allocation was successful

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10266>
This commit is contained in:
Icecream95
2021-04-16 09:48:58 +12:00
committed by Marge Bot
parent fc9b3b260e
commit 716ce3cc1a

View File

@@ -824,6 +824,7 @@ panfrost_ptr_map(struct pipe_context *pctx,
/* We don't have s/w routines for AFBC, so use a staging texture */
if (drm_is_afbc(rsrc->image.layout.modifier)) {
struct panfrost_resource *staging = pan_alloc_staging(ctx, rsrc, level, box);
assert(staging);
/* Staging resources have one LOD: level 0. Query the strides
* on this LOD.