Module: Mesa
Branch: main
Commit: db4b365f2b3283eba82883fdf12cfb4caa3121d9
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=db4b365f2b3283eba82883fdf12cfb4caa3121d9

Author: Lucas Stach <[email protected]>
Date:   Fri Jul 14 23:32:06 2023 +0200

etnaviv: initialize VIVS_GL_BUG_FIXES

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 <[email protected]>
Reviewed-by: Christian Gmeiner <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24166>

---

 src/gallium/drivers/etnaviv/etnaviv_context.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/gallium/drivers/etnaviv/etnaviv_context.c 
b/src/gallium/drivers/etnaviv/etnaviv_context.c
index baf9c17b699..fdb361d054a 100644
--- a/src/gallium/drivers/etnaviv/etnaviv_context.c
+++ b/src/gallium/drivers/etnaviv/etnaviv_context.c
@@ -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));

Reply via email to