Commit dffabc8f authored by Tvrtko Ursulin's avatar Tvrtko Ursulin

drm/i915/tracepoints: Rename i915_gem_request_notify

i915_gem_ring_notify is more appropriate since we do not have
the request information at this point, but it is simply a
signal from the engine that some request has been completed.

v2:
  * Always trace and log if there were any waiters.
  * Rename to intel_engine_notify. (Chris Wilson)
Signed-off-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
parent 354d036f
...@@ -1033,10 +1033,12 @@ static void ironlake_rps_change_irq_handler(struct drm_i915_private *dev_priv) ...@@ -1033,10 +1033,12 @@ static void ironlake_rps_change_irq_handler(struct drm_i915_private *dev_priv)
static void notify_ring(struct intel_engine_cs *engine) static void notify_ring(struct intel_engine_cs *engine)
{ {
bool waiters;
atomic_inc(&engine->irq_count); atomic_inc(&engine->irq_count);
set_bit(ENGINE_IRQ_BREADCRUMB, &engine->irq_posted); set_bit(ENGINE_IRQ_BREADCRUMB, &engine->irq_posted);
if (intel_engine_wakeup(engine)) waiters = intel_engine_wakeup(engine);
trace_i915_gem_request_notify(engine); trace_intel_engine_notify(engine, waiters);
} }
static void vlv_c0_read(struct drm_i915_private *dev_priv, static void vlv_c0_read(struct drm_i915_private *dev_priv,
......
...@@ -501,24 +501,27 @@ trace_i915_gem_request_execute(struct drm_i915_gem_request *req) ...@@ -501,24 +501,27 @@ trace_i915_gem_request_execute(struct drm_i915_gem_request *req)
#endif #endif
#endif #endif
TRACE_EVENT(i915_gem_request_notify, TRACE_EVENT(intel_engine_notify,
TP_PROTO(struct intel_engine_cs *engine), TP_PROTO(struct intel_engine_cs *engine, bool waiters),
TP_ARGS(engine), TP_ARGS(engine, waiters),
TP_STRUCT__entry( TP_STRUCT__entry(
__field(u32, dev) __field(u32, dev)
__field(u32, ring) __field(u32, ring)
__field(u32, seqno) __field(u32, seqno)
__field(bool, waiters)
), ),
TP_fast_assign( TP_fast_assign(
__entry->dev = engine->i915->drm.primary->index; __entry->dev = engine->i915->drm.primary->index;
__entry->ring = engine->id; __entry->ring = engine->id;
__entry->seqno = intel_engine_get_seqno(engine); __entry->seqno = intel_engine_get_seqno(engine);
__entry->waiters = waiters;
), ),
TP_printk("dev=%u, ring=%u, seqno=%u", TP_printk("dev=%u, ring=%u, seqno=%u, waiters=%u",
__entry->dev, __entry->ring, __entry->seqno) __entry->dev, __entry->ring, __entry->seqno,
__entry->waiters)
); );
DEFINE_EVENT(i915_gem_request, i915_gem_request_retire, DEFINE_EVENT(i915_gem_request, i915_gem_request_retire,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment