From: Daniel Vetter <daniel@ffwll.ch>
To: Jani Nikula <jani.nikula@linux.intel.com>
Cc: drm-intel-fixes@lists.freedesktop.org, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915/bxt: Don't save/restore eDP panel power during suspend (v3)
Date: Thu, 7 Jan 2016 10:28:09 +0100 [thread overview]
Message-ID: <20160107092809.GJ8076@phenom.ffwll.local> (raw)
In-Reply-To: <87h9ip24cb.fsf@intel.com>
On Thu, Jan 07, 2016 at 10:15:00AM +0200, Jani Nikula wrote:
> On Wed, 06 Jan 2016, Matt Roper <matthew.d.roper@intel.com> wrote:
> > Our attempts save/restore panel power state in i915_suspend.c are
> > causing unclaimed register warnings on BXT since the registers for this
> > platform differ from older platforms.
> >
> > The big hammer suspend/resume shouldn't be necessary for PP since the
> > connector/encoder hooks should already handle this. In theory we could
> > remove this for all platforms, but in practice it's likely that would
> > cause some regressions since older platforms with LVDS may have
> > incomplete PP handling. For now we'll leave the PCH save/restore alone
> > and change the non-PCH branch to only operate on gen <= 4 so that BXT
> > and future platforms aren't included.
> >
> > v2: Typo fix: s/||/&&/
> >
> > v3: Change non-PCH condition to a gen <= 4 test rather than listing
> > VLV/CHV/BXT as specific platforms to exclude; should be more
> > future-proof as we add new platforms. (Daniel)
> >
> > Cc: Vandana Kannan <vandana.kannan@intel.com>
> > Cc: Jani Nikula <jani.nikula@linux.intel.com>
> > Cc: Daniel Vetter <daniel@ffwll.ch>
> > Cc: drm-intel-fixes@lists.freedesktop.org
> > Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
> > ---
> > Although it's the direction we want to move, I'm not brave enough to blow away
> > the entire PP save/restore for all platforms since I don't have the HW
> > necessary to deal with the regressions that might pop up. The consensus on IRC
> > is that there probably will be a few regressions when we do that, so I'd rather
> > have people with appropriate platform access make those changes.
>
> This is the first step we want to take anyway.
>
> Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Just looked at this some more, and the code here is the only code that
restores PP registers. Except for vlv/chv, where we have a call to
intel_dp_init_panel_power_sequencer_registers in vlv_power_sequencer_pipe.
I think we first need to sprinkle more calls to restore PP registers
around before we can disable this here for bxt. This patch here just
papers over a legit bug, without fixing it really.
-Daniel
>
>
>
> >
> > drivers/gpu/drm/i915/i915_suspend.c | 4 ++--
> > 1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/i915/i915_suspend.c b/drivers/gpu/drm/i915/i915_suspend.c
> > index a2aa09c..a8af594 100644
> > --- a/drivers/gpu/drm/i915/i915_suspend.c
> > +++ b/drivers/gpu/drm/i915/i915_suspend.c
> > @@ -49,7 +49,7 @@ static void i915_save_display(struct drm_device *dev)
> > dev_priv->regfile.savePP_ON_DELAYS = I915_READ(PCH_PP_ON_DELAYS);
> > dev_priv->regfile.savePP_OFF_DELAYS = I915_READ(PCH_PP_OFF_DELAYS);
> > dev_priv->regfile.savePP_DIVISOR = I915_READ(PCH_PP_DIVISOR);
> > - } else if (!IS_VALLEYVIEW(dev) && !IS_CHERRYVIEW(dev)) {
> > + } else if (INTEL_INFO(dev)->gen <= 4) {
> > dev_priv->regfile.savePP_CONTROL = I915_READ(PP_CONTROL);
> > dev_priv->regfile.savePP_ON_DELAYS = I915_READ(PP_ON_DELAYS);
> > dev_priv->regfile.savePP_OFF_DELAYS = I915_READ(PP_OFF_DELAYS);
> > @@ -84,7 +84,7 @@ static void i915_restore_display(struct drm_device *dev)
> > I915_WRITE(PCH_PP_OFF_DELAYS, dev_priv->regfile.savePP_OFF_DELAYS);
> > I915_WRITE(PCH_PP_DIVISOR, dev_priv->regfile.savePP_DIVISOR);
> > I915_WRITE(PCH_PP_CONTROL, dev_priv->regfile.savePP_CONTROL);
> > - } else if (!IS_VALLEYVIEW(dev) && !IS_CHERRYVIEW(dev)) {
> > + } else if (INTEL_INFO(dev)->gen <= 4) {
> > I915_WRITE(PP_ON_DELAYS, dev_priv->regfile.savePP_ON_DELAYS);
> > I915_WRITE(PP_OFF_DELAYS, dev_priv->regfile.savePP_OFF_DELAYS);
> > I915_WRITE(PP_DIVISOR, dev_priv->regfile.savePP_DIVISOR);
>
> --
> Jani Nikula, Intel Open Source Technology Center
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-01-07 9:28 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-06 1:44 [PATCH] drm/i915/bxt: Don't save/restore eDP panel power during suspend Matt Roper
2016-01-06 1:47 ` [PATCH] drm/i915/bxt: Don't save/restore eDP panel power during suspend (v2) Matt Roper
2016-01-06 8:20 ` Daniel Vetter
2016-01-06 17:53 ` [PATCH] drm/i915/bxt: Don't save/restore eDP panel power during suspend (v3) Matt Roper
2016-01-07 8:15 ` Jani Nikula
2016-01-07 9:28 ` Daniel Vetter [this message]
2016-01-07 9:40 ` Jani Nikula
2016-01-07 14:39 ` Daniel Vetter
2016-02-02 18:14 ` Imre Deak
2016-01-06 2:06 ` [PATCH] drm/i915/bxt: Don't save/restore eDP panel power during suspend kbuild test robot
2016-01-06 6:04 ` kbuild test robot
2016-01-06 12:20 ` ✓ success: Fi.CI.BAT Patchwork
2016-01-07 7:20 ` 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=20160107092809.GJ8076@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=drm-intel-fixes@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jani.nikula@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.