i965/gen7: Fix the length of the MULTISAMPLE state packet in the HiZ op.
authorEric Anholt <eric@anholt.net>
Wed, 8 Feb 2012 23:12:56 +0000 (15:12 -0800)
committerEric Anholt <eric@anholt.net>
Fri, 10 Feb 2012 03:03:19 +0000 (19:03 -0800)
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
src/mesa/drivers/dri/i965/gen6_hiz.c

index 4a82d3d..a86c147 100644 (file)
@@ -101,7 +101,7 @@ gen6_hiz_emit_batch_head(struct brw_context *brw)
       int length = intel->gen == 7 ? 4 : 3;
 
       BEGIN_BATCH(length);
-      OUT_BATCH(_3DSTATE_MULTISAMPLE << 16 | (3 - 2));
+      OUT_BATCH(_3DSTATE_MULTISAMPLE << 16 | (length - 2));
       OUT_BATCH(MS_PIXEL_LOCATION_CENTER |
                 MS_NUMSAMPLES_1);
       OUT_BATCH(0);