diff --git a/src/gallium/drivers/zink/zink_context.c b/src/gallium/drivers/zink/zink_context.c index 2ce83441bcf..ad3b489e58c 100644 --- a/src/gallium/drivers/zink/zink_context.c +++ b/src/gallium/drivers/zink/zink_context.c @@ -2706,7 +2706,7 @@ static void reapply_color_write(struct zink_context *ctx) { struct zink_screen *screen = zink_screen(ctx->base.screen); - if (!screen->driver_workarounds.color_write_missing) { + if (screen->info.have_EXT_color_write_enable) { const VkBool32 enables[PIPE_MAX_COLOR_BUFS] = {1, 1, 1, 1, 1, 1, 1, 1}; const VkBool32 disables[PIPE_MAX_COLOR_BUFS] = {0}; const unsigned max_att = MIN2(PIPE_MAX_COLOR_BUFS, screen->info.props.limits.maxColorAttachments); @@ -2824,7 +2824,7 @@ zink_set_color_write_enables(struct zink_context *ctx) if (disable_color_writes && ctx->clears_enabled) zink_batch_rp(ctx); ctx->disable_color_writes = disable_color_writes; - if (zink_screen(ctx->base.screen)->driver_workarounds.color_write_missing) { + if (zink_screen(ctx->base.screen)->info.have_EXT_color_write_enable) { /* use dummy color buffers instead of the more sane option */ zink_batch_no_rp(ctx); ctx->rp_changed = true; diff --git a/src/gallium/drivers/zink/zink_framebuffer.c b/src/gallium/drivers/zink/zink_framebuffer.c index 8fc540bbb17..217aa5bfdba 100644 --- a/src/gallium/drivers/zink/zink_framebuffer.c +++ b/src/gallium/drivers/zink/zink_framebuffer.c @@ -140,7 +140,7 @@ fail: bool zink_use_dummy_attachments(const struct zink_context *ctx) { - return ctx->disable_color_writes && zink_screen(ctx->base.screen)->driver_workarounds.color_write_missing; + return ctx->disable_color_writes && zink_screen(ctx->base.screen)->info.have_EXT_color_write_enable; } struct zink_framebuffer * diff --git a/src/gallium/drivers/zink/zink_pipeline.c b/src/gallium/drivers/zink/zink_pipeline.c index 00f874423b7..543ca373277 100644 --- a/src/gallium/drivers/zink/zink_pipeline.c +++ b/src/gallium/drivers/zink/zink_pipeline.c @@ -248,7 +248,7 @@ zink_create_gfx_pipeline(struct zink_screen *screen, if (screen->info.dynamic_state2_feats.extendedDynamicState2PatchControlPoints) dynamicStateEnables[state_count++] = VK_DYNAMIC_STATE_PATCH_CONTROL_POINTS_EXT; } - if (!screen->driver_workarounds.color_write_missing) + if (screen->info.have_EXT_color_write_enable) dynamicStateEnables[state_count++] = VK_DYNAMIC_STATE_COLOR_WRITE_ENABLE_EXT; VkPipelineRasterizationLineStateCreateInfoEXT rast_line_state; @@ -473,7 +473,7 @@ zink_create_gfx_pipeline_output(struct zink_screen *screen, struct zink_gfx_pipe if (state->sample_locations_enabled) dynamicStateEnables[state_count++] = VK_DYNAMIC_STATE_SAMPLE_LOCATIONS_EXT; } - if (!screen->driver_workarounds.color_write_missing) + if (screen->info.have_EXT_color_write_enable) dynamicStateEnables[state_count++] = VK_DYNAMIC_STATE_COLOR_WRITE_ENABLE_EXT; assert(state_count < ARRAY_SIZE(dynamicStateEnables)); diff --git a/src/gallium/drivers/zink/zink_screen.c b/src/gallium/drivers/zink/zink_screen.c index 97585322bfc..af914d1ed02 100644 --- a/src/gallium/drivers/zink/zink_screen.c +++ b/src/gallium/drivers/zink/zink_screen.c @@ -2248,9 +2248,6 @@ init_driver_workarounds(struct zink_screen *screen) if (!screen->driver_workarounds.force_pipeline_library) screen->info.have_EXT_graphics_pipeline_library = false; screen->driver_workarounds.broken_l4a4 = screen->info.driver_props.driverID == VK_DRIVER_ID_NVIDIA_PROPRIETARY; - screen->driver_workarounds.color_write_missing = - !screen->info.have_EXT_color_write_enable || - !screen->info.cwrite_feats.colorWriteEnable; screen->driver_workarounds.depth_clip_control_missing = !screen->info.have_EXT_depth_clip_control; if (screen->info.driver_props.driverID == VK_DRIVER_ID_AMD_PROPRIETARY) /* this completely breaks xfb somehow */ diff --git a/src/gallium/drivers/zink/zink_types.h b/src/gallium/drivers/zink/zink_types.h index d023f6ab314..28a98934461 100644 --- a/src/gallium/drivers/zink/zink_types.h +++ b/src/gallium/drivers/zink/zink_types.h @@ -1163,7 +1163,6 @@ struct zink_screen { struct { bool broken_l4a4; - bool color_write_missing; bool depth_clip_control_missing; bool implicit_sync; bool force_pipeline_library;