All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: Damien Lespiau <damien.lespiau@intel.com>,
	intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 2/7] drm/i915/skl: Derive the max CDCLK from DFSM
Date: Wed, 10 Jun 2015 15:19:10 +0300	[thread overview]
Message-ID: <87h9qf7o3l.fsf@intel.com> (raw)
In-Reply-To: <1433438495-16667-2-git-send-email-damien.lespiau@intel.com>

On Thu, 04 Jun 2015, Damien Lespiau <damien.lespiau@intel.com> wrote:
> Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
> ---
>  drivers/gpu/drm/i915/i915_reg.h      |  7 +++++++
>  drivers/gpu/drm/i915/intel_display.c | 13 ++++++++++++-
>  2 files changed, 19 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> index 0f72c0e..cfe262c 100644
> --- a/drivers/gpu/drm/i915/i915_reg.h
> +++ b/drivers/gpu/drm/i915/i915_reg.h
> @@ -5761,6 +5761,13 @@ enum skl_disp_power_wells {
>  #define HSW_NDE_RSTWRN_OPT	0x46408
>  #define  RESET_PCH_HANDSHAKE_ENABLE	(1<<4)
>  
> +#define SKL_DFSM			0x51000
> +#define SKL_DFSM_CDCLK_LIMIT_MASK	(0x3 << 23)
> +#define SKL_DFSM_CDCLK_LIMIT_675	(  0 << 23)
> +#define SKL_DFSM_CDCLK_LIMIT_540	(  1 << 23)
> +#define SKL_DFSM_CDCLK_LIMIT_450	(  2 << 23)
> +#define SKL_DFSM_CDCLK_LIMIT_337_5	(  3 << 23)

Removed the spaces after ( while applying due to checkpatch whine.

BR,
Jani.


> +
>  #define FF_SLICE_CS_CHICKEN2			0x20e4
>  #define  GEN9_TSG_BARRIER_ACK_DISABLE		(1<<8)
>  
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index a96f181..6989626 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -5631,7 +5631,18 @@ static void intel_update_max_cdclk(struct drm_device *dev)
>  {
>  	struct drm_i915_private *dev_priv = dev->dev_private;
>  
> -	if (IS_BROADWELL(dev))  {
> +	if (IS_SKYLAKE(dev)) {
> +		u32 limit = I915_READ(SKL_DFSM) & SKL_DFSM_CDCLK_LIMIT_MASK;
> +
> +		if (limit == SKL_DFSM_CDCLK_LIMIT_675)
> +			dev_priv->max_cdclk_freq = 675000;
> +		else if (limit == SKL_DFSM_CDCLK_LIMIT_540)
> +			dev_priv->max_cdclk_freq = 540000;
> +		else if (limit == SKL_DFSM_CDCLK_LIMIT_450)
> +			dev_priv->max_cdclk_freq = 450000;
> +		else
> +			dev_priv->max_cdclk_freq = 337500;
> +	} else if (IS_BROADWELL(dev))  {
>  		/*
>  		 * FIXME with extra cooling we can allow
>  		 * 540 MHz for ULX and 675 Mhz for ULT.
> -- 
> 2.1.0
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2015-06-10 12:17 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-04 17:21 [PATCH 1/7] drm/i915: Make broxton_set_cdclk() static Damien Lespiau
2015-06-04 17:21 ` [PATCH 2/7] drm/i915/skl: Derive the max CDCLK from DFSM Damien Lespiau
2015-06-10 12:19   ` Jani Nikula [this message]
2015-06-04 17:21 ` [PATCH 3/7] drm/i915/skl: Don't warn if reading back DPLL0 is disabled Damien Lespiau
2015-06-04 17:21 ` [PATCH 4/7] drm/i915: Don't display the boot CDCLK twice Damien Lespiau
2015-06-04 17:21 ` [PATCH 5/7] drm/i915/skl: Update the cached CDCLK at the end of set_cdclk() Damien Lespiau
2015-06-04 17:21 ` [PATCH 6/7] drm/i915/bxt: Use intel_update_cdclk() to update dev_priv->cdclk_freq Damien Lespiau
2015-06-04 17:21 ` [PATCH 7/7] drm/i915/skl: Warn if the cached cdclk freq is not the requested one Damien Lespiau
2015-06-05 12:24   ` Ville Syrjälä
2015-06-05 12:40     ` Damien Lespiau
2015-06-05 12:42       ` Ville Syrjälä
2015-06-05 16:40   ` shuang.he
2015-06-05 12:23 ` [PATCH 1/7] drm/i915: Make broxton_set_cdclk() static Ville Syrjälä
2015-06-10 12:19   ` Jani Nikula

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=87h9qf7o3l.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=damien.lespiau@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /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.