i965: Set the correct WM GRF start reg on gen6.
authorZhenyu Wang <zhenyuw@linux.intel.com>
Sun, 13 Jun 2010 04:19:38 +0000 (21:19 -0700)
committerEric Anholt <eric@anholt.net>
Sun, 13 Jun 2010 04:47:31 +0000 (21:47 -0700)
src/mesa/drivers/dri/i965/gen6_wm_state.c

index 1eb17ca627d7e2dd5c5fb282a86d4c81b1dfb3ae..ed1a72f03bae4f1544a3c60c4ab80671400a50ad 100644 (file)
@@ -98,7 +98,8 @@ upload_wm_state(struct brw_context *brw)
 
    /* CACHE_NEW_SAMPLER */
    dw2 |= (ALIGN(brw->wm.sampler_count, 4) / 4) << GEN6_WM_SAMPLER_COUNT_SHIFT;
-   dw4 |= (1 << GEN6_WM_DISPATCH_START_GRF_SHIFT_0);
+   dw4 |= (brw->wm.prog_data->first_curbe_grf <<
+          GEN6_WM_DISPATCH_START_GRF_SHIFT_0);
 
    dw5 |= (40 - 1) << GEN6_WM_MAX_THREADS_SHIFT;
    dw5 |= GEN6_WM_DISPATCH_ENABLE;