drm/i915: hide (seqno-1) in ringbuffer code

Waiting for seqno-1 in our object synchronization code is an
implementation detail given how we've decided to do the waits within the
rest of our code.

Requested-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ben Widawsky <benjamin.widawsky@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
This commit is contained in:
Ben Widawsky
2012-04-11 11:18:21 -07:00
committed by Daniel Vetter
parent e3a5a2250a
commit 1500f7ea06
2 changed files with 7 additions and 1 deletions

View File

@@ -482,6 +482,12 @@ intel_ring_sync(struct intel_ring_buffer *waiter,
MI_SEMAPHORE_COMPARE |
MI_SEMAPHORE_REGISTER;
/* Throughout all of the GEM code, seqno passed implies our current
* seqno is >= the last seqno executed. However for hardware the
* comparison is strictly greater than.
*/
seqno -= 1;
ret = intel_ring_begin(waiter, 4);
if (ret)
return ret;