diff options
author | Owain Ainsworth <oga@cvs.openbsd.org> | 2009-11-25 13:37:49 +0000 |
---|---|---|
committer | Owain Ainsworth <oga@cvs.openbsd.org> | 2009-11-25 13:37:49 +0000 |
commit | 9eaddb9d60d50832f5f4bb9aab5062708ef28b20 (patch) | |
tree | 10d981da87fb23220557eeb1909142bafcc18380 /sys/dev | |
parent | eaf00103a5a336721acf60fc3bd840bceb234b65 (diff) |
oopsy. don't fuck the offset when we wrap the ring with NOOPs.
fixes the lockups for claudio.
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/pci/drm/i915_drv.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/pci/drm/i915_drv.c b/sys/dev/pci/drm/i915_drv.c index 472f1647e66..e365ffd2b49 100644 --- a/sys/dev/pci/drm/i915_drv.c +++ b/sys/dev/pci/drm/i915_drv.c @@ -354,6 +354,8 @@ inteldrm_wrap_ring(struct drm_i915_private *dev_priv) inteldrm_wait_ring(dev_priv, rem) != 0) return; /* XXX */ + dev_priv->ring.space -= rem; + bus_space_set_region_4(dev_priv->bst, dev_priv->ring.bsh, dev_priv->ring.woffset, MI_NOOP, rem / 4); @@ -394,7 +396,7 @@ inteldrm_advance_ring(struct drm_i915_private *dev_priv) { INTELDRM_VPRINTF("%s: %x, %x\n", __func__, dev_priv->ring.wspace, dev_priv->ring.woffset); - I915_WRITE(PRB0_TAIL, dev_priv->ring.woffset); + I915_WRITE(PRB0_TAIL, dev_priv->ring.tail); } void |