diff --git a/src/panfrost/vulkan/panvk_vX_blend.c b/src/panfrost/vulkan/panvk_vX_blend.c index be89f1ac8d2..37b6ae121ca 100644 --- a/src/panfrost/vulkan/panvk_vX_blend.c +++ b/src/panfrost/vulkan/panvk_vX_blend.c @@ -240,6 +240,10 @@ blend_needs_shader(const struct pan_blend_state *state, unsigned rt_idx, if (!GENX(pan_blendable_format_from_pipe_format)(rt->format)->internal) return true; + bool supports_2src = pan_blend_supports_2src(PAN_ARCH); + if (!pan_blend_can_fixed_function(rt->equation, supports_2src)) + return true; + unsigned constant_mask = pan_blend_constant_mask(rt->equation); /* v6 doesn't support blend constants in FF blend equations. */ @@ -263,10 +267,6 @@ blend_needs_shader(const struct pan_blend_state *state, unsigned rt_idx, return true; } - bool supports_2src = pan_blend_supports_2src(PAN_ARCH); - if (!pan_blend_can_fixed_function(rt->equation, supports_2src)) - return true; - /* Update the fixed function blend constant, if we use it. */ if (blend_const != ~0) *ff_blend_constant = blend_const;