asahi: Fix compressed ZS support

Depth/stencil formats are "not renderable" but do support compression.

I swear I already fixed this at some point and the commit must've fallen
through the cracks...

Signed-off-by: Asahi Lina <lina@asahilina.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22353>
This commit is contained in:
Asahi Lina 2023-04-06 01:42:51 +09:00 committed by Marge Bot
parent 2296f69629
commit 9db36376a6

View file

@ -405,7 +405,8 @@ agx_compression_allowed(const struct agx_resource *pres)
* renderable formats. As framebuffer compression, other formats don't make a
* ton of sense to compress anyway.
*/
if (!agx_pixel_format[pres->base.format].renderable) {
if (!agx_pixel_format[pres->base.format].renderable &&
!util_format_is_depth_or_stencil(pres->base.format)) {
rsrc_debug(pres, "No compression: format not renderable\n");
return false;
}