All of lore.kernel.org
 help / color / mirror / Atom feed
From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
To: ville.syrjala@linux.intel.com, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH v2 2/2] drm/i915: Fix clock readout when pipes are enabled w/o ports
Date: Thu, 27 Aug 2015 15:11:56 +0200	[thread overview]
Message-ID: <55DF0C9C.70103@linux.intel.com> (raw)
In-Reply-To: <1440607159-14453-1-git-send-email-ville.syrjala@linux.intel.com>

Op 26-08-15 om 18:39 schreef ville.syrjala@linux.intel.com:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> The BIOS sometimes likes to enable pipes w/o any ports, at least on
> older machines. Currently we fail to assign anything sensible to
> crtc->hwmode.crtc_clock which leads to complaints from the vblank code.
> Deal with active pipes w/o ports and assign something sensible to
> crtc_clock in i9xx_get_pipe_config(). The encoder .get_config() will
> override this if the port is enabled.
>
> Gets rid of rest of these on my gen4:
> [drm:drm_calc_timestamping_constants [drm]] *ERROR* crtc 24: Can't calculate constants, dotclock = 0!
> [drm:i915_get_vblank_timestamp] crtc 1 is disabled
>
> v2: Fill out crtc_clock already in i9xx_get_pipe_config() (Maarten)
>
> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
>  drivers/gpu/drm/i915/intel_display.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index dde8597..9e92915 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -8107,6 +8107,14 @@ static bool i9xx_get_pipe_config(struct intel_crtc *crtc,
>  	else
>  		i9xx_crtc_clock_get(crtc, pipe_config);
>  
> +	/*
> +	 * Normally the dotclock is filled in by the encoder .get_config()
> +	 * but in case the pipe is enabled w/o any ports we need a sane
> +	 * default.
> +	 */
> +	pipe_config->base.adjusted_mode.crtc_clock =
> +		pipe_config->port_clock / pipe_config->pixel_multiplier;
> +
>  	return true;
>  }
>  
This patch + 1/2 and 3/2.

Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>

I'll send a separate patch for killing off the plane sanitization. :)
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

      parent reply	other threads:[~2015-08-27 13:13 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-13 17:31 [PATCH 1/2] drm/i915: Assign hwmode after encoder state readout ville.syrjala
2015-08-13 17:31 ` [PATCH 2/2] drm/i915: Fix clock readout when pipes are enabld w/o ports ville.syrjala
2015-08-26 16:39   ` [PATCH v2 2/2] drm/i915: Fix clock readout when pipes are enabled " ville.syrjala
2015-08-26 16:39     ` [PATCH 3/2] drm/i915: Factor out intel_crtc_has_encoders() ville.syrjala
2015-08-27  7:29       ` Jani Nikula
2015-09-01 10:03         ` Daniel Vetter
2015-08-27 13:11     ` Maarten Lankhorst [this message]

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=55DF0C9C.70103@linux.intel.com \
    --to=maarten.lankhorst@linux.intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=ville.syrjala@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.