etnaviv: initialize VIVS_GL_BUG_FIXES
authorLucas Stach <l.stach@pengutronix.de>
Fri, 14 Jul 2023 21:32:06 +0000 (23:32 +0200)
committerMarge Bot <emma+marge@anholt.net>
Wed, 19 Jul 2023 16:35:04 +0000 (16:35 +0000)
Same as the blob, always initialize this state when feature
BUG_FIXES18 is present.

Fixes spec@!opengl 2.0@occlusion-query-discard on GC3000.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24166>

src/gallium/drivers/etnaviv/etnaviv_context.c

index baf9c17..fdb361d 100644 (file)
@@ -468,6 +468,9 @@ etna_reset_gpu_state(struct etna_context *ctx)
       etna_set_state(stream, VIVS_GL_UNK03854, 0x00000000);
    }
 
+   if (VIV_FEATURE(screen, chipMinorFeatures4, BUG_FIXES18))
+      etna_set_state(stream, VIVS_GL_BUG_FIXES, 0x6);
+
    if (!screen->specs.use_blt) {
       /* Enable SINGLE_BUFFER for resolve, if supported */
       etna_set_state(stream, VIVS_RS_SINGLE_BUFFER, COND(screen->specs.single_buffer, VIVS_RS_SINGLE_BUFFER_ENABLE));