asahi: Set cfg.levels for linear framebuffers

Otherwise we will crash in GenXML, which does not specify a default here.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19606>
This commit is contained in:
Asahi Lina 2022-11-08 10:35:00 -05:00 committed by Marge Bot
parent a5b8918800
commit 2aac18d7e4

View file

@ -804,6 +804,7 @@ agx_set_framebuffer_state(struct pipe_context *pctx,
if (tex->layout.tiling == AIL_TILING_LINEAR) {
cfg.stride = ail_get_linear_stride_B(&tex->layout, level) - 4;
cfg.levels = 1;
} else {
cfg.unk_tiled = true;
cfg.levels = tex->base.last_level + 1;