aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_ringbuffer.h
diff options
context:
space:
mode:
authorJohn Harrison <John.C.Harrison@Intel.com>2014-11-24 13:49:39 -0500
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-12-03 03:35:24 -0500
commit581c26e8a26482eb9d8072a35978034e2dd16b9d (patch)
treed10a6ff18236fe08894c579a6e1dfb52d1b307e1 /drivers/gpu/drm/i915/intel_ringbuffer.h
parent3a8a946efbe0312f7a3d074163499f13d38dfb08 (diff)
drm/i915: Convert 'trace_irq' to use requests rather than seqnos
Updated the trace_irq code to use requests instead of seqnos. This includes reference counting the request object to ensure it sticks around when required. Note that getting access to the reference counting functions means moving the inline i915_trace_irq_get() function from intel_ringbuffer.h to i915_drv.h. For: VIZ-4377 Signed-off-by: John Harrison <John.C.Harrison@Intel.com> Reviewed-by: Thomas Daniel <Thomas.Daniel@intel.com> [danvet: Resolve conflict due to shuffled merge order.] 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.h8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.h b/drivers/gpu/drm/i915/intel_ringbuffer.h
index 2a84bd9688a8..39e303d83e91 100644
--- a/drivers/gpu/drm/i915/intel_ringbuffer.h
+++ b/drivers/gpu/drm/i915/intel_ringbuffer.h
@@ -142,7 +142,7 @@ struct intel_engine_cs {
142 142
143 unsigned irq_refcount; /* protected by dev_priv->irq_lock */ 143 unsigned irq_refcount; /* protected by dev_priv->irq_lock */
144 u32 irq_enable_mask; /* bitmask to enable ring interrupt */ 144 u32 irq_enable_mask; /* bitmask to enable ring interrupt */
145 u32 trace_irq_seqno; 145 struct drm_i915_gem_request *trace_irq_req;
146 bool __must_check (*irq_get)(struct intel_engine_cs *ring); 146 bool __must_check (*irq_get)(struct intel_engine_cs *ring);
147 void (*irq_put)(struct intel_engine_cs *ring); 147 void (*irq_put)(struct intel_engine_cs *ring);
148 148
@@ -442,10 +442,4 @@ intel_ring_get_request(struct intel_engine_cs *ring)
442 return ring->outstanding_lazy_request; 442 return ring->outstanding_lazy_request;
443} 443}
444 444
445static inline void i915_trace_irq_get(struct intel_engine_cs *ring, u32 seqno)
446{
447 if (ring->trace_irq_seqno == 0 && ring->irq_get(ring))
448 ring->trace_irq_seqno = seqno;
449}
450
451#endif /* _INTEL_RINGBUFFER_H_ */ 445#endif /* _INTEL_RINGBUFFER_H_ */