All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Imre Deak <imre.deak@intel.com>
Cc: intel-gfx@lists.freedesktop.org, kristen@linux.intel.com
Subject: Re: [PATCH 4/4] drm/i915: make sure PC8 is enabled on suspend and disabled on resume
Date: Mon, 2 Jun 2014 18:05:04 +0200	[thread overview]
Message-ID: <20140602160504.GC19050@phenom.ffwll.local> (raw)
In-Reply-To: <1401724638.1590.26.camel@intelbox>

On Mon, Jun 02, 2014 at 06:57:18PM +0300, Imre Deak wrote:
> On Mon, 2014-06-02 at 17:32 +0200, Daniel Vetter wrote:
> > On Mon, Jun 02, 2014 at 02:37:35PM +0300, Imre Deak wrote:
> > > On Mon, 2014-06-02 at 10:45 +0200, Daniel Vetter wrote:
> > > > On Thu, May 29, 2014 at 02:11:37PM -0700, Jesse Barnes wrote:
> > > > > From: Kristen Carlson Accardi <kristen@linux.intel.com>
> > > > > 
> > > > > This matches the runtime suspend paths and allows the system to enter
> > > > > the lowest power mode at freeze time.
> > > > > 
> > > > > Signed-off-by: Kristen Carlson Accardi <kristen@linux.intel.com>
> > > > > Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
> > > > 
> > > > pc8 is fully subsumed into runtime pm by now. Do we _really_ still need
> > > > this?
> > > 
> > > Yes, since the system suspend/resume handlers are called with an RPM ref
> > > held and thus PC8 disabled.
> > 
> > But doesn't patch 1 try to fix that?
> 
> That only disables the display side, but we won't disable PC8 until the
> RPM suspend handler is called. And that won't happen because the last
> RPM ref is held by the DPM framework for the duration of system
> suspend/resume handlers.

Yeah, there's discussion going on to make system suspend be optionally
based upon runtime pm in the core. Atm that's not possible since the
system wakes up everyone to suspend them.

> > Imo we should have this here but instead go through highl-level the runtime
> > pm functions to shut off the chip on all platforms.
> 
> After the planned refactoring we could have a low-level function that we
> can call both from here and the runtime PM path, but until that happens
> we need to do this here directly.

Yeah, that's what I'm actually aiming for - we should be able to call the
runtime pm suspend code from the system suspend code and share pretty much
all the code. The sequence I'm thinking of would be for system suspend:

1. Stop everything we need to stop (gpu, display, rps, ...) to be able to
enter runtime pm.

2. Check for leaked references. This might be tricky because audio.

3. Call runtime pm suspend hooks.

Resume would be the same, but inverted.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

  reply	other threads:[~2014-06-02 16:05 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-29 21:11 [PATCH 1/4] drm/i915: disable power wells on suspend Jesse Barnes
2014-05-29 21:11 ` [PATCH 2/4] drm/i915: leave rc6 enabled at suspend time Jesse Barnes
2014-05-30 12:54   ` Imre Deak
2014-05-30 15:32     ` Jesse Barnes
2014-05-30 15:40       ` Chris Wilson
2014-05-30 18:20         ` Jesse Barnes
2014-06-02  8:43       ` Daniel Vetter
2014-05-30 18:33   ` [PATCH] drm/i915: leave rc6 enabled at suspend time v2 Jesse Barnes
2014-06-04 19:33     ` [PATCH] drm/i915: leave rc6 enabled at suspend time v3 Jesse Barnes
2014-06-04 20:45       ` [PATCH] drm/i915: leave rc6 enabled at suspend time v4 Jesse Barnes
2014-06-05  9:21         ` Daniel Vetter
2014-06-05 15:50           ` Jesse Barnes
2014-06-10 13:42         ` Imre Deak
2014-06-10 13:57           ` Daniel Vetter
2014-06-10 14:41             ` Imre Deak
2014-06-10 15:26               ` Daniel Vetter
2014-06-11 22:21                 ` Jesse Barnes
2014-06-11 22:24                   ` Jesse Barnes
2014-06-12 15:08                     ` Imre Deak
2014-05-30 19:00   ` [PATCH 2/4] drm/i915: leave rc6 enabled at suspend time Kristen Carlson Accardi
2014-05-29 21:11 ` [PATCH 3/4] drm/i915: send proper opregion notifications on suspend/resume Jesse Barnes
2014-05-29 21:48   ` [PATCH 3/5] ACPI: export target system state for use by drivers Jesse Barnes
2014-05-30  2:09     ` Rafael J. Wysocki
2014-05-29 21:48   ` [PATCH 4/5] drm/i915: send proper opregion notifications on suspend/resume Jesse Barnes
2014-05-30 13:47   ` [PATCH 3/4] " Imre Deak
2014-05-30 19:08   ` Kristen Carlson Accardi
2014-05-29 21:11 ` [PATCH 4/4] drm/i915: make sure PC8 is enabled on suspend and disabled on resume Jesse Barnes
2014-05-30 13:37   ` Imre Deak
2014-05-30 18:29     ` Jesse Barnes
2014-05-30 21:12       ` Rafael J. Wysocki
2014-05-30 21:05         ` Jesse Barnes
2014-05-30 18:32   ` [PATCH] drm/i915: make sure PC8 is enabled on suspend and disabled on resume v2 Jesse Barnes
2014-05-30 18:40     ` [PATCH] drm/i915: make sure PC8 is enabled on suspend and disabled on resume v3 Jesse Barnes
2014-05-30 18:48       ` [PATCH] drm/i915: make sure PC8 is enabled on suspend and disabled on resume v4 Jesse Barnes
2014-06-04 20:02         ` Imre Deak
2014-06-02  8:45   ` [PATCH 4/4] drm/i915: make sure PC8 is enabled on suspend and disabled on resume Daniel Vetter
2014-06-02 11:37     ` Imre Deak
2014-06-02 15:32       ` Daniel Vetter
2014-06-02 15:57         ` Imre Deak
2014-06-02 16:05           ` Daniel Vetter [this message]
2014-05-30 12:48 ` [PATCH 1/4] drm/i915: disable power wells on suspend Imre Deak
2014-05-30 18:59   ` Kristen Carlson Accardi

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=20140602160504.GC19050@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=imre.deak@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=kristen@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.