Commit a36b7dcc authored by Keith Packard's avatar Keith Packard Committed by Dave Airlie

drm/i965: On I965, use correct 3DSTATE_DRAWING_RECTANGLE command in vblank

The batchbuffer submission paths were fixed to use the 965-specific command,
but the vblank tasklet was not. When the older version is sent, the 965 will
lock up.
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent f1c3e67e
...@@ -125,16 +125,26 @@ static void i915_vblank_tasklet(struct drm_device *dev) ...@@ -125,16 +125,26 @@ static void i915_vblank_tasklet(struct drm_device *dev)
i915_kernel_lost_context(dev); i915_kernel_lost_context(dev);
BEGIN_LP_RING(6); if (IS_I965G(dev)) {
BEGIN_LP_RING(4);
OUT_RING(GFX_OP_DRAWRECT_INFO);
OUT_RING(0); OUT_RING(GFX_OP_DRAWRECT_INFO_I965);
OUT_RING(0); OUT_RING(0);
OUT_RING(sarea_priv->width | sarea_priv->height << 16); OUT_RING(((sarea_priv->width - 1) & 0xffff) | ((sarea_priv->height - 1) << 16));
OUT_RING(sarea_priv->width | sarea_priv->height << 16); OUT_RING(0);
OUT_RING(0); ADVANCE_LP_RING();
} else {
ADVANCE_LP_RING(); BEGIN_LP_RING(6);
OUT_RING(GFX_OP_DRAWRECT_INFO);
OUT_RING(0);
OUT_RING(0);
OUT_RING(sarea_priv->width | sarea_priv->height << 16);
OUT_RING(sarea_priv->width | sarea_priv->height << 16);
OUT_RING(0);
ADVANCE_LP_RING();
}
sarea_priv->ctxOwner = DRM_KERNEL_CONTEXT; sarea_priv->ctxOwner = DRM_KERNEL_CONTEXT;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment