From: Daniel Vetter Subject: Re: commit drm/i915: disable shared panel fitter for pipe breaks resolution switching Date: Sun, 7 Apr 2013 20:56:51 +0200 Message-ID: <20130407185651.GI2228@phenom.ffwll.local> References: <513255BC.80201@xmsnet.nl> <51378D4D.8020203@xmsnet.nl> <513CBCA8.2040403@xmsnet.nl> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-ea0-f181.google.com (mail-ea0-f181.google.com [209.85.215.181]) by gabe.freedesktop.org (Postfix) with ESMTP id 34EBCE5C60 for ; Sun, 7 Apr 2013 11:53:53 -0700 (PDT) Received: by mail-ea0-f181.google.com with SMTP id z10so2012813ead.40 for ; Sun, 07 Apr 2013 11:53:52 -0700 (PDT) Content-Disposition: inline In-Reply-To: <513CBCA8.2040403@xmsnet.nl> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: Hans de Bruin Cc: Daniel Vetter , intel-gfx List-Id: intel-gfx@lists.freedesktop.org On Sun, Mar 10, 2013 at 06:02:32PM +0100, Hans de Bruin wrote: > On 03/06/2013 11:37 PM, Daniel Vetter wrote: > >On Wed, Mar 6, 2013 at 7:39 PM, Hans de Bruin wrote: > >>On 03/06/2013 03:00 PM, Daniel Vetter wrote: > >>> > >>>Hi Hans, > >>> > >>>Can you please test with 3.9-rc1? That contains an additional patch > >>>which might prevent the regression. Specifically > >>> > >>>commit 9d6d9f19e8146fa24903cb561e204a22232740e3 > >>>Author: Mika Kuoppala > >>>Date: Fri Feb 8 16:35:38 2013 +0200 > >>> > >>> drm/i915: clean up panel fitter handling in lvds > >> > >> > >>Today's kernel still contains the bug. > > > >Hm, I've just retested latest drm-intel-nightly which should have the > >same set of relevant patches, and I couldn't reproduce your issue. > >Low-res modes on the lvds panel seem to correctly scale up here on my > >945gm. > > > >Can you pls retest with latest -nightly from > >http://cgit.freedesktop.org/~danvet/drm-intel ? > > > >Also please attach the output of xrandr --verbose when running with a > >reduced mode. > > > > tested: > http://cgit.freedesktop.org/~danvet/drm-intel > commit d08a6eb2690b1ac6f0582feb41c2ccbea945285f > Date: Thu Mar 7 22:54:25 2013 +0100 > > The problem is still there > > > my previous post contained the xrandr output whiteout the verbose. > Doe you want my to repost with the verbose option? Sorry for the long delay in taking again a look at this. I've tried to reproduce this on my various machines similar to yours, but totally failed. Also, a bunch of people with matching machines to yours actually claim that the 2 commits which regress for you actually fix up lvds panel fiting for them. So I'm a bit lost as to what's going on here. Can you please try the below debug patch on top of latest 3.9-rc kernels? Please boot that kernel with drm.debug=0xe added to your kernel cmdline, reproduce the issue (preferrably with xrandr --output LVDS --mode ...) and then attach the complete dmesg. This will enable lots of debugging, so please make sure you grab everything starting from when i915.ko loads. Thanks, Daniel diff --git a/drivers/gpu/drm/i915/intel_lvds.c b/drivers/gpu/drm/i915/intel_lvds.c index ca2d903..7b2122f 100644 --- a/drivers/gpu/drm/i915/intel_lvds.c +++ b/drivers/gpu/drm/i915/intel_lvds.c @@ -155,6 +155,12 @@ static void intel_pre_enable_lvds(struct intel_encoder *encoder) struct drm_device *dev = encoder->base.dev; struct intel_lvds_encoder *enc = to_lvds_encoder(&encoder->base); struct drm_i915_private *dev_priv = dev->dev_private; + uint32_t tmp = I915_READ(PFIT_CONTROL); + + WARN(tmp, "pfit control is dirty: 0x%08x\n", tmp); + assert_pipe_disabled(dev_priv, + INTEL_INFO(dev)->gen < 4 || (tmp & PFIT_PIPE_MASK) ? + PIPE_B : PIPE_A); if (HAS_PCH_SPLIT(dev) || !enc->pfit_control) return; @@ -171,6 +177,10 @@ static void intel_pre_enable_lvds(struct intel_encoder *encoder) I915_WRITE(PFIT_PGM_RATIOS, enc->pfit_pgm_ratios); I915_WRITE(PFIT_CONTROL, enc->pfit_control); + + DRM_DEBUG_KMS("panel-fitter state: %x, %x\n", + I915_READ(PFIT_CONTROL), + I915_READ(PFIT_PGM_RATIOS)); } /** -- Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch