From 613722e046a8f797003375adf73ef40acd180cc7 Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Wed, 21 Apr 2021 12:25:45 -0400 Subject: [PATCH] panfrost/blend: Workaround a v7 implementation-detail Signed-off-by: Alyssa Rosenzweig Part-of: --- src/panfrost/lib/pan_blend.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/panfrost/lib/pan_blend.c b/src/panfrost/lib/pan_blend.c index 8b14d4c..937ccc1 100644 --- a/src/panfrost/lib/pan_blend.c +++ b/src/panfrost/lib/pan_blend.c @@ -101,6 +101,11 @@ can_blend_constant(const struct panfrost_device *dev, if (dev->arch == 6) return false; + /* v7 only uses the constant from RT 0 (TODO: what if it's the same + * constant? or a constant is shared?) */ + if (dev->arch == 7 && rt > 0) + return false; + unsigned first_constant = ffs(constant_mask) - 1; float constant = state->constants[first_constant]; -- 2.7.4