From: Daniel Vetter <daniel@ffwll.ch>
To: ville.syrjala@linux.intel.com
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH v4 5/9] drm/i915: Add pipe update trace points
Date: Tue, 29 Apr 2014 13:17:12 +0200 [thread overview]
Message-ID: <20140429111712.GO32404@phenom.ffwll.local> (raw)
In-Reply-To: <1398767752-619-6-git-send-email-ville.syrjala@linux.intel.com>
On Tue, Apr 29, 2014 at 01:35:48PM +0300, ville.syrjala@linux.intel.com wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> Add trace points for observing the atomic pipe update mechanism.
>
> v2: Rebased due to earlier changes
> v3: Pass intel_crtc instead of drm_crtc (Daniel)
> v4: Pass frame counter from the caller to evaded/end since
> the caller now always has that ready
>
> Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org>
> Reviewed-by: Sourab Gupta <sourabgupta@gmail.com>
> Reviewed-by: Akash Goel <akash.goels@gmail.com>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Merged up to this one here. Can you please update the review-AR for Akash
and Sourab for the remaining patches?
Thanks, Daniel
> ---
> drivers/gpu/drm/i915/i915_trace.h | 75 +++++++++++++++++++++++++++++++++++++
> drivers/gpu/drm/i915/intel_sprite.c | 6 +++
> 2 files changed, 81 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/i915_trace.h b/drivers/gpu/drm/i915/i915_trace.h
> index 23c26f1..b29d7b1 100644
> --- a/drivers/gpu/drm/i915/i915_trace.h
> +++ b/drivers/gpu/drm/i915/i915_trace.h
> @@ -7,6 +7,7 @@
>
> #include <drm/drmP.h>
> #include "i915_drv.h"
> +#include "intel_drv.h"
> #include "intel_ringbuffer.h"
>
> #undef TRACE_SYSTEM
> @@ -14,6 +15,80 @@
> #define TRACE_SYSTEM_STRING __stringify(TRACE_SYSTEM)
> #define TRACE_INCLUDE_FILE i915_trace
>
> +/* pipe updates */
> +
> +TRACE_EVENT(i915_pipe_update_start,
> + TP_PROTO(struct intel_crtc *crtc, u32 min, u32 max),
> + TP_ARGS(crtc, min, max),
> +
> + TP_STRUCT__entry(
> + __field(enum pipe, pipe)
> + __field(u32, frame)
> + __field(u32, scanline)
> + __field(u32, min)
> + __field(u32, max)
> + ),
> +
> + TP_fast_assign(
> + __entry->pipe = crtc->pipe;
> + __entry->frame = crtc->base.dev->driver->get_vblank_counter(crtc->base.dev,
> + crtc->pipe);
> + __entry->scanline = intel_get_crtc_scanline(crtc);
> + __entry->min = min;
> + __entry->max = max;
> + ),
> +
> + TP_printk("pipe %c, frame=%u, scanline=%u, min=%u, max=%u",
> + pipe_name(__entry->pipe), __entry->frame,
> + __entry->scanline, __entry->min, __entry->max)
> +);
> +
> +TRACE_EVENT(i915_pipe_update_vblank_evaded,
> + TP_PROTO(struct intel_crtc *crtc, u32 min, u32 max, u32 frame),
> + TP_ARGS(crtc, min, max, frame),
> +
> + TP_STRUCT__entry(
> + __field(enum pipe, pipe)
> + __field(u32, frame)
> + __field(u32, scanline)
> + __field(u32, min)
> + __field(u32, max)
> + ),
> +
> + TP_fast_assign(
> + __entry->pipe = crtc->pipe;
> + __entry->frame = frame;
> + __entry->scanline = intel_get_crtc_scanline(crtc);
> + __entry->min = min;
> + __entry->max = max;
> + ),
> +
> + TP_printk("pipe %c, frame=%u, scanline=%u, min=%u, max=%u",
> + pipe_name(__entry->pipe), __entry->frame,
> + __entry->scanline, __entry->min, __entry->max)
> +);
> +
> +TRACE_EVENT(i915_pipe_update_end,
> + TP_PROTO(struct intel_crtc *crtc, u32 frame),
> + TP_ARGS(crtc, frame),
> +
> + TP_STRUCT__entry(
> + __field(enum pipe, pipe)
> + __field(u32, frame)
> + __field(u32, scanline)
> + ),
> +
> + TP_fast_assign(
> + __entry->pipe = crtc->pipe;
> + __entry->frame = frame;
> + __entry->scanline = intel_get_crtc_scanline(crtc);
> + ),
> +
> + TP_printk("pipe %c, frame=%u, scanline=%u",
> + pipe_name(__entry->pipe), __entry->frame,
> + __entry->scanline)
> +);
> +
> /* object tracking */
>
> TRACE_EVENT(i915_gem_object_create,
> diff --git a/drivers/gpu/drm/i915/intel_sprite.c b/drivers/gpu/drm/i915/intel_sprite.c
> index 6192e58..213cd58 100644
> --- a/drivers/gpu/drm/i915/intel_sprite.c
> +++ b/drivers/gpu/drm/i915/intel_sprite.c
> @@ -73,6 +73,8 @@ static bool intel_pipe_update_start(struct intel_crtc *crtc, uint32_t *start_vbl
>
> local_irq_disable();
>
> + trace_i915_pipe_update_start(crtc, min, max);
> +
> for (;;) {
> /*
> * prepare_to_wait() has a memory barrier, which guarantees
> @@ -104,6 +106,8 @@ static bool intel_pipe_update_start(struct intel_crtc *crtc, uint32_t *start_vbl
>
> *start_vbl_count = dev->driver->get_vblank_counter(dev, pipe);
>
> + trace_i915_pipe_update_vblank_evaded(crtc, min, max, *start_vbl_count);
> +
> return true;
> }
>
> @@ -113,6 +117,8 @@ static void intel_pipe_update_end(struct intel_crtc *crtc, u32 start_vbl_count)
> enum pipe pipe = crtc->pipe;
> u32 end_vbl_count = dev->driver->get_vblank_counter(dev, pipe);
>
> + trace_i915_pipe_update_end(crtc, end_vbl_count);
> +
> local_irq_enable();
>
> if (start_vbl_count != end_vbl_count)
> --
> 1.8.3.2
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
next prev parent reply other threads:[~2014-04-29 11:17 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-29 10:35 [PATCH v4 0/9] drm/i915: Atomic sprites v4 ville.syrjala
2014-04-29 10:35 ` [PATCH 1/9] drm/i915: Fix scanout position for real ville.syrjala
2014-04-29 10:35 ` [PATCH v4 2/9] drm/i915: Add intel_get_crtc_scanline() ville.syrjala
2014-04-29 10:35 ` [PATCH v8 3/9] drm/i915: Make sprite updates atomic ville.syrjala
[not found] ` <CAHofq8MHrbki1XtXeMZGSDSABnu4LUkZDfbYWCvU5Nng0AjM5g@mail.gmail.com>
[not found] ` <E1F41119A09A1C4EACAB7A4603D2A6C918F9F47E@BGSMSX104.gar.corp.intel.com>
2014-05-19 10:38 ` FW: " Arun Murthy
2014-05-19 10:49 ` Ville Syrjälä
2014-05-19 11:08 ` Arun Murthy
2014-05-19 10:49 ` Murthy, Arun R
2014-05-19 10:57 ` G, Pallavi
2014-05-22 13:03 ` Daniel Vetter
2014-05-22 13:24 ` Ville Syrjälä
2014-04-29 10:35 ` [PATCH v2 4/9] drm/i915: Perform primary enable/disable atomically with sprite updates ville.syrjala
2014-05-19 10:13 ` G, Pallavi
2014-04-29 10:35 ` [PATCH v4 5/9] drm/i915: Add pipe update trace points ville.syrjala
2014-04-29 11:17 ` Daniel Vetter [this message]
2014-04-29 11:46 ` Ville Syrjälä
2014-04-29 10:35 ` [PATCH 6/9] drm/i915: Add a small adjustment to the pixel counter on interlaced modes ville.syrjala
2014-05-15 14:53 ` akash goel
2014-05-16 2:42 ` sourab gupta
2014-05-16 10:49 ` Ville Syrjälä
2014-04-29 10:35 ` [PATCH 7/9] drm/i915: Improve gen3/4 frame counter ville.syrjala
2014-05-15 14:46 ` akash goel
2014-05-16 2:37 ` sourab gupta
2014-04-29 10:35 ` [PATCH v2 8/9] drm/i915: Draw a picture about video timings ville.syrjala
2014-05-15 15:10 ` akash goel
2014-05-15 17:20 ` [PATCH v3 " ville.syrjala
2014-05-16 2:54 ` sourab gupta
2014-04-29 10:35 ` [PATCH 9/9] drm/i915: Fix gen2 and hsw scanline counter ville.syrjala
2014-05-15 17:23 ` [PATCH v2 9/9] drm/i915: Fix gen2 and hsw+ " ville.syrjala
2014-05-16 5:33 ` akash goel
2014-05-16 6:24 ` sourab gupta
2014-05-21 9:01 ` Ville Syrjälä
2014-04-29 10:44 ` [PATCH v4 0/9] drm/i915: Atomic sprites v4 Ville Syrjälä
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140429111712.GO32404@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=intel-gfx@lists.freedesktop.org \
--cc=ville.syrjala@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox