summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarek Vasut <[email protected]>2020-03-22 03:48:05 +0100
committerEric Engestrom <[email protected]>2020-03-30 12:26:37 +0200
commit96868b7297b42eb52b1bf2c0f291e8b1a4176ba5 (patch)
treeb7619aa4a64d70367478c9423ad34652e8091c7d
parent2e745e0ed350b55e8e26dc0e9bf4423f0c3c7fda (diff)
etnaviv: Emit PE.ALPHA_COLOR_EXT* on GPUs with half-float support
At least GC880 (iMX6S), GC2000 (iMX6Q) blobs do not emit the PE.ALPHA_COLOR_EXT0 and PE.ALPHA_COLOR_EXT1 into the command stream. The GCnano (STM32MP1) is not affected by this change either. This is because neither of these GPUs support the half-float feature. Emit PE.ALPHA_COLOR_EXT* in etnaviv only if half-float support is present in the GPU. This fixes all of the currently failing dEQPs in this group: dEQP-GLES2.functional.fragment_ops.blend.* Fixes: 76adf041f25 ("etnaviv: fix blend color on newer GPUs") Signed-off-by: Marek Vasut <[email protected]> Reviewed-by: Christian Gmeiner <[email protected]> Reviewed-by: Jonathan Marek <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4277> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4277> (cherry picked from commit 9e78f17b74a862e34891901cde8292f91adeb655)
-rw-r--r--.pick_status.json2
-rw-r--r--src/gallium/drivers/etnaviv/etnaviv_emit.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/.pick_status.json b/.pick_status.json
index a397a511fde..742bf1363ed 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -211,7 +211,7 @@
"description": "etnaviv: Emit PE.ALPHA_COLOR_EXT* on GPUs with half-float support",
"nominated": true,
"nomination_type": 1,
- "resolution": 0,
+ "resolution": 1,
"master_sha": null,
"because_sha": "76adf041f25defad204abea1ed49b82fd9c264d1"
},
diff --git a/src/gallium/drivers/etnaviv/etnaviv_emit.c b/src/gallium/drivers/etnaviv/etnaviv_emit.c
index b92cf770cf4..c3a37c4c454 100644
--- a/src/gallium/drivers/etnaviv/etnaviv_emit.c
+++ b/src/gallium/drivers/etnaviv/etnaviv_emit.c
@@ -532,7 +532,8 @@ etna_emit_state(struct etna_context *ctx)
/*014A8*/ EMIT_STATE(PE_DITHER(x), blend->PE_DITHER[x]);
}
}
- if (unlikely(dirty & (ETNA_DIRTY_BLEND_COLOR))) {
+ if (unlikely(dirty & (ETNA_DIRTY_BLEND_COLOR)) &&
+ VIV_FEATURE(ctx->screen, chipMinorFeatures1, HALF_FLOAT)) {
/*014B0*/ EMIT_STATE(PE_ALPHA_COLOR_EXT0, ctx->blend_color.PE_ALPHA_COLOR_EXT0);
/*014B4*/ EMIT_STATE(PE_ALPHA_COLOR_EXT1, ctx->blend_color.PE_ALPHA_COLOR_EXT1);
}