All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915/execlists: Use list_safe_reset_next()	instead of opencoding
Date: Mon, 05 Dec 2016 11:13:13 +0200	[thread overview]
Message-ID: <87vauyyc0m.fsf@intel.com> (raw)
In-Reply-To: <20161203182517.25018-1-chris@chris-wilson.co.uk>

On Sat, 03 Dec 2016, Chris Wilson <chris@chris-wilson.co.uk> wrote:
> list.h provides a macro for updating the next element in a safe
> list-iter, so let's use it so that it is hopefully clearer to the reader
> about the unusual behaviour, and also easier to grep.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

Reviewed-by: Jani Nikula <jani.nikula@intel.com>

> ---
>  drivers/gpu/drm/i915/intel_lrc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_lrc.c b/drivers/gpu/drm/i915/intel_lrc.c
> index a579088bddbd..1ad1468edbf9 100644
> --- a/drivers/gpu/drm/i915/intel_lrc.c
> +++ b/drivers/gpu/drm/i915/intel_lrc.c
> @@ -733,7 +733,7 @@ static void execlists_schedule(struct drm_i915_gem_request *request, int prio)
>  			if (prio > READ_ONCE(p->signaler->priority))
>  				list_move_tail(&p->dfs_link, &dfs);
>  
> -		p = list_next_entry(dep, dfs_link);
> +		list_safe_reset_next(dep, p, dfs_link);
>  		if (!RB_EMPTY_NODE(&pt->node))
>  			continue;

-- 
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

      parent reply	other threads:[~2016-12-05  9:13 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-03 18:25 [PATCH] drm/i915/execlists: Use list_safe_reset_next() instead of opencoding Chris Wilson
2016-12-03 19:07 ` ✗ Fi.CI.BAT: failure for " Patchwork
2016-12-05  9:13 ` Jani Nikula [this message]

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=87vauyyc0m.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=chris@chris-wilson.co.uk \
    --cc=intel-gfx@lists.freedesktop.org \
    /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.