From: Dave Gordon <david.s.gordon@intel.com>
To: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>,
Intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915/guc: Do not use wait_for_atomic in host2guc_action
Date: Tue, 28 Jun 2016 16:50:43 +0100 [thread overview]
Message-ID: <57729CD3.8000004@intel.com> (raw)
In-Reply-To: <1467124241-1306-1-git-send-email-tvrtko.ursulin@linux.intel.com>
On 28/06/16 15:30, Tvrtko Ursulin wrote:
> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
>
> host2guc_action does not appear to be called from atomic context
> so a more polite wait_for macro should be used. Especially since
> the timeout is 10ms.
Maybe. However we don't really want to sleep if the action takes only a
few microseconds, which some of them do. Maybe we need an optimistic
spin for a few uS to handle the quick commands followed by a sleeping
wait in the cases where it takes long enough that we don't mind the
extra wakeup latency?
.Dave.
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Reported-by: Imre Deak <imre.deak@intel.com>
> Cc: Dave Gordon <david.s.gordon@intel.com>
> Cc: Imre Deak <imre.deak@intel.com>
> ---
> drivers/gpu/drm/i915/i915_guc_submission.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_guc_submission.c b/drivers/gpu/drm/i915/i915_guc_submission.c
> index 355b6475e74c..fcc7982f8141 100644
> --- a/drivers/gpu/drm/i915/i915_guc_submission.c
> +++ b/drivers/gpu/drm/i915/i915_guc_submission.c
> @@ -98,7 +98,7 @@ static int host2guc_action(struct intel_guc *guc, u32 *data, u32 len)
> I915_WRITE(HOST2GUC_INTERRUPT, HOST2GUC_TRIGGER);
>
> /* No HOST2GUC command should take longer than 10ms */
> - ret = wait_for_atomic(host2guc_action_response(dev_priv, &status), 10);
> + ret = wait_for(host2guc_action_response(dev_priv, &status), 10);
> if (status != GUC2HOST_STATUS_SUCCESS) {
> /*
> * Either the GuC explicitly returned an error (which
>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-06-28 15:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-28 14:30 [PATCH] drm/i915/guc: Do not use wait_for_atomic in host2guc_action Tvrtko Ursulin
2016-06-28 15:06 ` ✗ Ro.CI.BAT: failure for " Patchwork
2016-06-28 15:50 ` Dave Gordon [this message]
2016-06-28 16:04 ` [PATCH] " Tvrtko Ursulin
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=57729CD3.8000004@intel.com \
--to=david.s.gordon@intel.com \
--cc=Intel-gfx@lists.freedesktop.org \
--cc=tvrtko.ursulin@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.