All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Paulo Zanoni <paulo.r.zanoni@intel.com>
Cc: intel-gfx@lists.freedesktop.org,
	Arthur J Runyan <arthur.j.runyan@intel.com>
Subject: Re: [PATCH] drm/i915: configure the transcoder clocks before touching pipeconf on HSW+
Date: Mon, 30 Apr 2018 21:12:12 +0300	[thread overview]
Message-ID: <20180430181212.GE23723@intel.com> (raw)
In-Reply-To: <20180427231208.9092-1-paulo.r.zanoni@intel.com>

On Fri, Apr 27, 2018 at 04:12:08PM -0700, Paulo Zanoni wrote:
> For all platforms that run haswell_crtc_enable, our spec tells us to
> configure the transcoder clocks before it tells us to set pipeconf and
> the other pipe/transcoder/plane registers.
> 
> For some reason we've been able to get away with doing what we were
> doing until now, but starting from Icelake, we get machine hangs if we
> try to touch the pipe/transcoder registers without having the clocks
> configured.
> 
> So this patch changes all the relevant platforms to call
> intel_ddi_enable_pipe_clock at the point we're supposed to, according
> to the spec.

I don't think this really matches the spec. You're now enabling the
clock before configuring the port stuff and link training. So AFAICS
intel_ddi_enable_pipe_clock() seems to be in the correct place, but
we're just configuring all the pipe/transcoder/etc. stuff way too
early.

> 
> It seems there is a way to work around this problem on ICL with some
> chicken bit, but I still couldn't find which one it is, and it's
> better if we just do the right thing here.
> 
> Cc: Arthur J Runyan <arthur.j.runyan@intel.com>
> Cc: James Ausmus <james.ausmus@intel.com>
> Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
> ---
>  drivers/gpu/drm/i915/intel_display.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> Luckily our CI system should be in a spot where it is able to tell us
> whether this patch is good with high confidence. I haven't tested it
> on every affected platform.
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 48576ea2d36c..c93aed2ec16d 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -5578,8 +5578,11 @@ static void haswell_crtc_enable(struct intel_crtc_state *pipe_config,
>  				     &intel_crtc->config->fdi_m_n, NULL);
>  	}
>  
> -	if (!transcoder_is_dsi(cpu_transcoder))
> +	if (!transcoder_is_dsi(cpu_transcoder)) {
> +		intel_ddi_enable_pipe_clock(pipe_config);
> +
>  		haswell_set_pipeconf(crtc);
> +	}
>  
>  	haswell_set_pipemisc(crtc);
>  
> @@ -5589,9 +5592,6 @@ static void haswell_crtc_enable(struct intel_crtc_state *pipe_config,
>  
>  	intel_encoders_pre_enable(crtc, pipe_config, old_state);
>  
> -	if (!transcoder_is_dsi(cpu_transcoder))
> -		intel_ddi_enable_pipe_clock(pipe_config);
> -
>  	/* Display WA #1180: WaDisableScalarClockGating: glk, cnl */
>  	psl_clkgate_wa = (IS_GEMINILAKE(dev_priv) || IS_CANNONLAKE(dev_priv)) &&
>  			 intel_crtc->config->pch_pfit.enabled;
> -- 
> 2.14.3
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Ville Syrjälä
Intel
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2018-04-30 18:12 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-27 23:12 [PATCH] drm/i915: configure the transcoder clocks before touching pipeconf on HSW+ Paulo Zanoni
2018-04-30 11:28 ` ✓ Fi.CI.BAT: success for " Patchwork
2018-04-30 12:17 ` Patchwork
2018-04-30 12:40 ` Patchwork
2018-04-30 14:20 ` ✓ Fi.CI.IGT: " Patchwork
2018-04-30 15:36 ` Patchwork
2018-04-30 16:18 ` Patchwork
2018-04-30 18:12 ` Ville Syrjälä [this message]
2018-05-02 21:06   ` [PATCH] " Paulo Zanoni
2018-05-02 21:58 ` [PATCH] drm/i915: enable the pipe/transcoder/planes later " Paulo Zanoni
2018-05-02 22:07   ` Rodrigo Vivi
2018-05-02 22:19   ` Manasi Navare
2018-05-02 22:23 ` ✗ Fi.CI.BAT: failure for drm/i915: configure the transcoder clocks before touching pipeconf on HSW+ (rev2) Patchwork
2018-05-04 19:56   ` Paulo Zanoni
2018-05-02 23:47 ` Patchwork
2018-05-08  0:10 ` ✓ Fi.CI.BAT: success " Patchwork
2018-05-08  0:57 ` ✗ Fi.CI.IGT: failure " 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=20180430181212.GE23723@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=arthur.j.runyan@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=paulo.r.zanoni@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.