ctx->blend->base.alpha_to_coverage);
/* Disable shader execution if we can */
- if (dev->quirks & MIDGARD_SHADERLESS
- && !panfrost_fs_required(fs, blend, rt_count)) {
- fragmeta->shader = 0x1;
+ if (!panfrost_fs_required(fs, blend, rt_count)) {
fragmeta->attribute_count = 0;
fragmeta->varying_count = 0;
fragmeta->texture_count = 0;
fragmeta->sampler_count = 0;
- /* This feature is not known to work on Bifrost */
struct mali_midgard_properties_packed prop;
- pan_pack(&prop, MIDGARD_PROPERTIES, cfg) {
- cfg.work_register_count = 1;
- cfg.depth_source = MALI_DEPTH_SOURCE_FIXED_FUNCTION;
- cfg.early_z_enable = true;
+ if (dev->quirks & IS_BIFROST) {
+ fragmeta->shader = 0x0;
+
+ pan_pack(&prop, BIFROST_PROPERTIES, cfg) {
+ cfg.unknown = 0x950020; /* XXX */
+ cfg.early_z_enable = true;
+ }
+ } else {
+ fragmeta->shader = 0x1;
+
+ pan_pack(&prop, MIDGARD_PROPERTIES, cfg) {
+ cfg.work_register_count = 1;
+ cfg.depth_source = MALI_DEPTH_SOURCE_FIXED_FUNCTION;
+ cfg.early_z_enable = true;
+ }
}
memcpy(&fragmeta->midgard_props, &prop, sizeof(prop));
/* What it says on the tin */
#define HAS_SWIZZLES (1 << 4)
-/* Support for setting shader to NULL for masking out colour (while allowing
- * Z/S updates to proceed) */
-
-#define MIDGARD_SHADERLESS (1 << 5)
+/* bit 5 unused */
/* Whether this GPU lacks support for any typed stores in blend shader,
* requiring packing instead */
case 0x750:
/* Someone should investigate the broken loads? */
return MIDGARD_QUIRKS | MIDGARD_NO_TYPED_BLEND_LOADS
- | NO_BLEND_PACKS | MIDGARD_SHADERLESS;
+ | NO_BLEND_PACKS;
case 0x860:
case 0x880:
- return MIDGARD_QUIRKS | MIDGARD_SHADERLESS;
+ return MIDGARD_QUIRKS;
case 0x6000: /* G71 */
return BIFROST_QUIRKS | HAS_SWIZZLES;