diff options
author | Ben Widawsky <ben@bwidawsk.net> | 2011-03-19 18:14:27 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2011-05-10 13:56:40 -0700 |
commit | 96f298aa9c9fc9b7c8a2ebaf8c195d178f570e09 (patch) | |
tree | cfb71da9613d701728520ec5f916e7cb6aa8a889 /drivers/gpu/drm/i915/i915_dma.c | |
parent | 2c34b850ee1e9f86b41706149d0954eee58757a3 (diff) |
drm/1915: ringbuffer wait for idle function
Added a new function which waits for the ringbuffer space to be equal to
(total - 8). This is the empty condition of the ringbuffer, and
equivalent to head==tail.
Also modified two users of this functionality elsewhere in the code.
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_dma.c')
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 12876f2795d..64c6f67777f 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c @@ -571,7 +571,7 @@ static int i915_quiescent(struct drm_device *dev) struct intel_ring_buffer *ring = LP_RING(dev->dev_private); i915_kernel_lost_context(dev); - return intel_wait_ring_buffer(ring, ring->size - 8); + return intel_wait_ring_idle(ring); } static int i915_flush_ioctl(struct drm_device *dev, void *data, |