i965/draw: Set NEW_AUX_STATE when draw aux changes
authorJason Ekstrand <jason.ekstrand@intel.com>
Wed, 24 Jan 2018 07:47:26 +0000 (23:47 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Thu, 25 Jan 2018 03:05:36 +0000 (19:05 -0800)
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104411
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104383
Fixes: ea0d2e98ecb369ab84e78c84709c0930ea8c293a
Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/brw_draw.c

index 04654f516e339b6a6a752cbfdac502931959d75f..268c200f4a9658a7c1918bd3da384fc4aa64c7aa 100644 (file)
@@ -553,7 +553,10 @@ brw_predraw_resolve_framebuffer(struct brw_context *brw,
          intel_miptree_render_aux_usage(brw, irb->mt, isl_format,
                                         blend_enabled,
                                         draw_aux_buffer_disabled[i]);
-      brw->draw_aux_usage[i] = aux_usage;
+      if (brw->draw_aux_usage[i] != aux_usage) {
+         brw->ctx.NewDriverState |= BRW_NEW_AUX_STATE;
+         brw->draw_aux_usage[i] = aux_usage;
+      }
 
       intel_miptree_prepare_render(brw, irb->mt, irb->mt_level,
                                    irb->mt_layer, irb->layer_count,