From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH 2/3] drm/i915: handle interrupts from the OA unit
Date: Fri, 17 Apr 2020 16:25:53 -0700 [thread overview]
Message-ID: <87lfmtu22m.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <20200413154822.11620-3-umesh.nerlige.ramappa@intel.com>
On Mon, 13 Apr 2020 08:48:21 -0700, Umesh Nerlige Ramappa wrote:
>
> diff --git a/drivers/gpu/drm/i915/gt/intel_gt_irq.c b/drivers/gpu/drm/i915/gt/intel_gt_irq.c
> index 0cc7dd54f4f9..61eee9fb8872 100644
> --- a/drivers/gpu/drm/i915/gt/intel_gt_irq.c
> +++ b/drivers/gpu/drm/i915/gt/intel_gt_irq.c
> @@ -94,6 +94,18 @@ gen11_gt_engine_identity(struct intel_gt *gt,
> return ident;
> }
>
> +static void notify_perfmon_buffer_half_full(struct drm_i915_private *i915)
> +{
> + atomic64_inc(&i915->perf.exclusive_stream->half_full_count);
> + wake_up_all(&i915->perf.exclusive_stream->poll_wq);
> +}
> +
I was expecting this function to be almost the same as the timer
oa_poll_check_timer_cb(), something like, maybe with minor variations:
static void notify_perfmon_buffer_half_full(struct drm_i915_private *i915)
{
struct i915_perf_stream *stream = i915->perf.exclusive_stream;
if (oa_buffer_check_unlocked(stream)) {
stream->pollin = true;
wake_up(&stream->poll_wq);
}
}
And consequently I was expecting to see zero changes to functions such as
oa_buffer_check_unlocked() and i915_perf_poll_locked() since everything
else is driven off stream->pollin as it is in case the timer callback.
So my question is why is notify_perfmon_buffer_half_full() not as I've
written above and what purpose are these new members half_full_count and
half_full_count_last serving? If it is to save a few cycles to adjust the
tail in oa_buffer_check_unlocked() (and I am not even sure of that) for an
interrupt which fires when half the buffer is full imo it is not worth it.
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2020-04-17 23:25 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-13 15:48 [Intel-gfx] [PATCH 0/3] drm/i915/perf: add OA interrupt support Umesh Nerlige Ramappa
2020-04-13 15:48 ` [Intel-gfx] [PATCH 1/3] drm/i915/perf: Reduce cpu overhead for blocking perf OA reads Umesh Nerlige Ramappa
2020-04-14 5:08 ` Dixit, Ashutosh
2020-04-14 6:58 ` Dixit, Ashutosh
2020-04-14 16:59 ` Umesh Nerlige Ramappa
2020-04-14 19:09 ` Dixit, Ashutosh
2020-04-14 19:37 ` Dixit, Ashutosh
2020-04-15 10:00 ` Lionel Landwerlin
2020-04-15 18:55 ` Umesh Nerlige Ramappa
2020-04-15 19:16 ` Lionel Landwerlin
2020-04-15 22:47 ` Umesh Nerlige Ramappa
2020-04-13 15:48 ` [Intel-gfx] [PATCH 2/3] drm/i915: handle interrupts from the OA unit Umesh Nerlige Ramappa
2020-04-17 23:25 ` Dixit, Ashutosh [this message]
2020-04-13 15:48 ` [Intel-gfx] [PATCH 3/3] drm/i915/perf: add interrupt enabling parameter Umesh Nerlige Ramappa
2020-04-17 23:26 ` Dixit, Ashutosh
2020-04-14 19:09 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for drm/i915/perf: add OA interrupt support (rev9) Patchwork
2020-04-14 19:28 ` [Intel-gfx] ✗ Fi.CI.DOCS: " Patchwork
2020-04-14 19:33 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2020-04-15 11:50 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
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=87lfmtu22m.wl-ashutosh.dixit@intel.com \
--to=ashutosh.dixit@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=umesh.nerlige.ramappa@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