All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Sultan Alsawaf <sultan@kerneltoast.com>
Cc: stable@vger.kernel.org
Subject: Re: [PATCH v3] drm/i915/gt: Schedule request retirement when timeline idles
Date: Sat, 18 Apr 2020 12:30:23 +0200	[thread overview]
Message-ID: <20200418103023.GB2816412@kroah.com> (raw)
In-Reply-To: <20200413152930.2930-1-sultan@kerneltoast.com>

On Mon, Apr 13, 2020 at 08:29:30AM -0700, Sultan Alsawaf wrote:
> From: Chris Wilson <chris@chris-wilson.co.uk>
> 
> commit 4f88f8747fa43c97c3b3712d8d87295ea757cc51 upstream.
> 
> The major drawback of commit 7e34f4e4aad3 ("drm/i915/gen8+: Add RC6 CTX
> corruption WA") is that it disables RC6 while Skylake (and friends) is
> active, and we do not consider the GPU idle until all outstanding
> requests have been retired and the engine switched over to the kernel
> context. If userspace is idle, this task falls onto our background idle
> worker, which only runs roughly once a second, meaning that userspace has
> to have been idle for a couple of seconds before we enable RC6 again.
> Naturally, this causes us to consume considerably more energy than
> before as powersaving is effectively disabled while a display server
> (here's looking at you Xorg) is running.
> 
> As execlists will get a completion event as each context is completed,
> we can use this interrupt to queue a retire worker bound to this engine
> to cleanup idle timelines. We will then immediately notice the idle
> engine (without userspace intervention or the aid of the background
> retire worker) and start parking the GPU. Thus during light workloads,
> we will do much more work to idle the GPU faster...  Hopefully with
> commensurate power saving!
> 
> v2: Watch context completions and only look at those local to the engine
> when retiring to reduce the amount of excess work we perform.
> 
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=112315
> References: 7e34f4e4aad3 ("drm/i915/gen8+: Add RC6 CTX corruption WA")
> References: 2248a28384fe ("drm/i915/gen8+: Add RC6 CTX corruption WA")
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Link: https://patchwork.freedesktop.org/patch/msgid/20191125105858.1718307-3-chris@chris-wilson.co.uk
> [Sultan: for the backport to 5.4, struct_mutex needs to be held while
>  retiring so that retirement doesn't race with vma destruction.]
> Signed-off-by: Sultan Alsawaf <sultan@kerneltoast.com>
> ---
>  drivers/gpu/drm/i915/gt/intel_engine_cs.c     |  2 +
>  drivers/gpu/drm/i915/gt/intel_engine_types.h  |  8 ++
>  drivers/gpu/drm/i915/gt/intel_lrc.c           |  8 ++
>  drivers/gpu/drm/i915/gt/intel_timeline.c      |  1 +
>  .../gpu/drm/i915/gt/intel_timeline_types.h    |  3 +
>  drivers/gpu/drm/i915/i915_request.c           | 75 +++++++++++++++++++
>  drivers/gpu/drm/i915/i915_request.h           |  4 +
>  7 files changed, 101 insertions(+)

Why are you not cc:ing all of the relevant people on these patches?
That's not ok, I'm just going to drop all of these requests until that
happens, and I get an ack from the developers/maintainers involved.

thanks,

greg k-h

  parent reply	other threads:[~2020-04-18 10:30 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-30  3:30 [PATCH 0/2] A couple of important fixes for i915 on 5.4 Sultan Alsawaf
2020-03-30  3:30 ` [Intel-gfx] " Sultan Alsawaf
2020-03-30  3:30 ` Sultan Alsawaf
2020-03-30  3:30 ` [PATCH 1/2] drm/i915: Disable Panel Self Refresh (PSR) by default Sultan Alsawaf
2020-03-30  8:51   ` Greg KH
2020-03-30 15:50     ` Sultan Alsawaf
2020-03-30  3:30 ` [PATCH 2/2] drm/i915/gt: Schedule request retirement when timeline idles Sultan Alsawaf
2020-03-30  3:30   ` [Intel-gfx] " Sultan Alsawaf
2020-03-30  3:30   ` Sultan Alsawaf
2020-03-30 15:56   ` Sultan Alsawaf
2020-03-30 15:56     ` [Intel-gfx] " Sultan Alsawaf
2020-03-30 15:56     ` Sultan Alsawaf
2020-03-30 16:27   ` Chris Wilson
2020-03-30 16:35     ` Sultan Alsawaf
2020-03-30 16:45       ` Chris Wilson
2020-04-07 20:28         ` Sultan Alsawaf
2020-04-07 20:43           ` [PATCH v2] " Sultan Alsawaf
2020-04-12  7:48             ` Sultan Alsawaf
2020-04-12  7:56               ` Greg KH
2020-04-13 14:37                 ` Salvatore Bonaccorso
2020-04-13 15:23                 ` Sultan Alsawaf
2020-04-13 15:29                   ` [PATCH v3] " Sultan Alsawaf
2020-04-17  9:38                     ` Sultan Alsawaf
2020-04-18 10:29                       ` Greg KH
2020-04-18 10:30                     ` Greg KH [this message]
2020-03-30  8:51 ` [PATCH 0/2] A couple of important fixes for i915 on 5.4 Greg KH
2020-03-30 15:55   ` Sultan Alsawaf
2020-03-30 15:55     ` [Intel-gfx] " Sultan Alsawaf
2020-03-30 15:55     ` Sultan Alsawaf

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=20200418103023.GB2816412@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=stable@vger.kernel.org \
    --cc=sultan@kerneltoast.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.