diff --git a/src/panfrost/lib/pan_blitter.c b/src/panfrost/lib/pan_blitter.c index ff75ecccd76..76d9a96a4a8 100644 --- a/src/panfrost/lib/pan_blitter.c +++ b/src/panfrost/lib/pan_blitter.c @@ -163,7 +163,13 @@ pan_blitter_prepare_bifrost_rsd(const struct panfrost_device *dev, rsd->properties.bifrost.pixel_kill_operation = MALI_PIXEL_KILL_FORCE_EARLY; } - rsd->properties.bifrost.allow_forward_pixel_to_kill = true; + + /* We can only allow blit shader fragments to kill if they write all + * colour outputs. This is true for our colour (non-Z/S) blit shaders, + * but obviously not true for Z/S shaders. */ + + rsd->properties.bifrost.allow_forward_pixel_to_kill = !(z || s); + rsd->preload.fragment.coverage = true; rsd->preload.fragment.sample_mask_id = ms; }