panfrost: Warn on going out of AFBC
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11830>
This commit is contained in:
parent
5bd91a632b
commit
bcd915622b
|
@ -265,7 +265,8 @@ panfrost_set_shader_images(
|
|||
/* Images don't work with AFBC, since they require pixel-level granularity */
|
||||
if (drm_is_afbc(rsrc->image.layout.modifier)) {
|
||||
pan_resource_modifier_convert(ctx, rsrc,
|
||||
DRM_FORMAT_MOD_ARM_16X16_BLOCK_U_INTERLEAVED);
|
||||
DRM_FORMAT_MOD_ARM_16X16_BLOCK_U_INTERLEAVED,
|
||||
"Shader image");
|
||||
}
|
||||
|
||||
util_copy_image_view(&ctx->images[shader][start_slot+i], image);
|
||||
|
|
|
@ -986,10 +986,12 @@ panfrost_ptr_map(struct pipe_context *pctx,
|
|||
void
|
||||
pan_resource_modifier_convert(struct panfrost_context *ctx,
|
||||
struct panfrost_resource *rsrc,
|
||||
uint64_t modifier)
|
||||
uint64_t modifier, const char *reason)
|
||||
{
|
||||
assert(!rsrc->modifier_constant);
|
||||
|
||||
perf_debug_ctx(ctx, "Disabling AFBC with a blit. Reason: %s", reason);
|
||||
|
||||
struct pipe_resource *tmp_prsrc =
|
||||
panfrost_resource_create_with_modifier(
|
||||
ctx->base.screen, &rsrc->base, modifier);
|
||||
|
|
|
@ -156,6 +156,6 @@ panfrost_translate_texture_dimension(enum pipe_texture_target t) {
|
|||
void
|
||||
pan_resource_modifier_convert(struct panfrost_context *ctx,
|
||||
struct panfrost_resource *rsrc,
|
||||
uint64_t modifier);
|
||||
uint64_t modifier, const char *reason);
|
||||
|
||||
#endif /* PAN_RESOURCE_H */
|
||||
|
|
Loading…
Reference in New Issue