diff options
author | Ben Widawsky <ben@bwidawsk.net> | 2013-05-28 19:22:18 -0700 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2013-05-31 20:54:08 +0200 |
commit | ad776f8b09d66e0145479fdbde2a710e5892441f (patch) | |
tree | 8fe32b87b70bc02bdad3f33efc4d1f50a86fe774 /drivers/gpu/drm/i915/intel_ringbuffer.h | |
parent | 5586181fce2b2e89a0e281d78ffbdfa103bb0dde (diff) | |
download | op-kernel-dev-ad776f8b09d66e0145479fdbde2a710e5892441f.zip op-kernel-dev-ad776f8b09d66e0145479fdbde2a710e5892441f.tar.gz |
drm/i915: Semaphore MBOX update generalization
This replaces the existing MBOX update code with a more generalized
calculation for emitting mbox updates. We also create a sentinel for
doing the updates so we can more abstractly deal with the rings.
When doing MBOX updates the code must be aware of the /other/ rings.
Until now the platforms which supported semaphores had a fixed number of
rings and so it made sense for the code to be very specialized
(hardcoded).
The patch does contain a functional change, but should have no
behavioral changes.
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Reviewed-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_ringbuffer.h')
-rw-r--r-- | drivers/gpu/drm/i915/intel_ringbuffer.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.h b/drivers/gpu/drm/i915/intel_ringbuffer.h index 24268fb..f55d92e 100644 --- a/drivers/gpu/drm/i915/intel_ringbuffer.h +++ b/drivers/gpu/drm/i915/intel_ringbuffer.h @@ -105,9 +105,12 @@ struct intel_ring_buffer { int (*sync_to)(struct intel_ring_buffer *ring, struct intel_ring_buffer *to, u32 seqno); + /* our mbox written by others */ u32 semaphore_register[I915_NUM_RINGS]; - u32 signal_mbox[2]; /* mboxes this ring signals to */ + /* mboxes this ring signals to */ + u32 signal_mbox[I915_NUM_RINGS]; + /** * List of objects currently involved in rendering from the * ringbuffer. |