diff --git a/src/gallium/drivers/panfrost/pan_context.c b/src/gallium/drivers/panfrost/pan_context.c index 0d6255112e7..e005a0a04bc 100644 --- a/src/gallium/drivers/panfrost/pan_context.c +++ b/src/gallium/drivers/panfrost/pan_context.c @@ -179,6 +179,14 @@ panfrost_get_blend(struct panfrost_batch *batch, unsigned rti, struct panfrost_b return 0; } + /* On Bifrost and newer, we can also use fixed-function for opaque + * output regardless of the format by configuring the appropriate + * conversion descriptor in the internal blend descriptor. (Midgard + * requires a blend shader even for this case.) + */ + if (dev->arch >= 6 && info.opaque) + return 0; + /* Otherwise, we need to grab a shader */ struct pan_blend_state pan_blend = blend->pan; unsigned nr_samples = surf->nr_samples ? : surf->texture->nr_samples; diff --git a/src/panfrost/lib/pan_blitter.c b/src/panfrost/lib/pan_blitter.c index d182f62e453..5e4d2f3a883 100644 --- a/src/panfrost/lib/pan_blitter.c +++ b/src/panfrost/lib/pan_blitter.c @@ -331,6 +331,7 @@ pan_blitter_get_blend_shaders(struct panfrost_device *dev, const struct pan_blit_shader_data *blit_shader, mali_ptr *blend_shaders) { +#if PAN_ARCH <= 5 if (!rt_count) return; @@ -403,6 +404,7 @@ pan_blitter_get_blend_shaders(struct panfrost_device *dev, pthread_mutex_unlock(&dev->blitter.shaders.lock); blend_shaders[i] = blend_shader->address; } +#endif } static const struct pan_blit_shader_data *