From: Damien Lespiau <damien.lespiau@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 3/4] drm/i915/skl: Gen9 coarse power gating
Date: Mon, 19 Jan 2015 15:39:28 +0000 [thread overview]
Message-ID: <20150119153928.GC30935@strange.ger.corp.intel.com> (raw)
In-Reply-To: <1421431648-22904-4-git-send-email-damien.lespiau@intel.com>
On Fri, Jan 16, 2015 at 06:07:27PM +0000, Damien Lespiau wrote:
> From: Zhe Wang <zhe1.wang@intel.com>
>
> Enable coarse power gating for Gen9. This feature allows render and
> media engine to enter RC6 independently. Policies are configured
> together with RC6. This feature will only be enabled when RC6 is
> enabled.
>
> Signed-off-by: Zhe Wang <zhe1.wang@intel.com>
> Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Reviewed-by: Damien Lespiau <damien.lespiau@intel.com>
--
Damien
> ---
> drivers/gpu/drm/i915/i915_reg.h | 3 +++
> drivers/gpu/drm/i915/intel_pm.c | 8 ++++++++
> 2 files changed, 11 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> index cb96041..3d08f9d 100644
> --- a/drivers/gpu/drm/i915/i915_reg.h
> +++ b/drivers/gpu/drm/i915/i915_reg.h
> @@ -6065,6 +6065,9 @@ enum skl_disp_power_wells {
> #define GEN6_PMINTRMSK 0xA168
> #define GEN8_PMINTR_REDIRECT_TO_NON_DISP (1<<31)
> #define VLV_PWRDWNUPCTL 0xA294
> +#define GEN9_MEDIA_PG_IDLE_HYSTERESIS 0xA0C4
> +#define GEN9_RENDER_PG_IDLE_HYSTERESIS 0xA0C8
> +#define GEN9_PG_ENABLE 0xA210
>
> #define VLV_CHICKEN_3 (VLV_DISPLAY_BASE + 0x7040C)
> #define PIXEL_OVERLAP_CNT_MASK (3 << 30)
> diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
> index f40b8f2..71bf4f4 100644
> --- a/drivers/gpu/drm/i915/intel_pm.c
> +++ b/drivers/gpu/drm/i915/intel_pm.c
> @@ -3892,6 +3892,7 @@ static void gen9_disable_rps(struct drm_device *dev)
> struct drm_i915_private *dev_priv = dev->dev_private;
>
> I915_WRITE(GEN6_RC_CONTROL, 0);
> + I915_WRITE(GEN9_PG_ENABLE, 0);
> }
>
> static void gen6_disable_rps(struct drm_device *dev)
> @@ -4081,6 +4082,10 @@ static void gen9_enable_rc6(struct drm_device *dev)
> I915_WRITE(GEN6_RC_SLEEP, 0);
> I915_WRITE(GEN6_RC6_THRESHOLD, 37500); /* 37.5/125ms per EI */
>
> + /* 2c: Program Coarse Power Gating Policies. */
> + I915_WRITE(GEN9_MEDIA_PG_IDLE_HYSTERESIS, 25);
> + I915_WRITE(GEN9_RENDER_PG_IDLE_HYSTERESIS, 25);
> +
> /* 3a: Enable RC6 */
> if (intel_enable_rc6(dev) & INTEL_RC6_ENABLE)
> rc6_mask = GEN6_RC_CTL_RC6_ENABLE;
> @@ -4090,6 +4095,9 @@ static void gen9_enable_rc6(struct drm_device *dev)
> GEN6_RC_CTL_EI_MODE(1) |
> rc6_mask);
>
> + /* 3b: Enable Coarse Power Gating only when RC6 is enabled */
> + I915_WRITE(GEN9_PG_ENABLE, (rc6_mask & GEN6_RC_CTL_RC6_ENABLE) ? 3 : 0);
> +
> gen6_gt_force_wake_put(dev_priv, FORCEWAKE_ALL);
>
> }
> --
> 1.8.3.1
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2015-01-19 15:40 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-16 18:07 [PATCH 0/4] SKL turbo part 1 Damien Lespiau
2015-01-16 18:07 ` [PATCH 1/4] drm/i915/skl: add turbo support Damien Lespiau
2015-01-19 10:02 ` Mika Kuoppala
2015-01-16 18:07 ` [PATCH 2/4] drm/i915/skl: Retrieve the frequency limits Damien Lespiau
2015-01-20 10:14 ` Daniel Vetter
2015-01-20 11:45 ` Damien Lespiau
2015-01-16 18:07 ` [PATCH 3/4] drm/i915/skl: Gen9 coarse power gating Damien Lespiau
2015-01-19 15:39 ` Damien Lespiau [this message]
2015-01-16 18:07 ` [PATCH 4/4] drm/i915/skl: Updated the RC6/Forcewake related debugfs interface for Gen9 Damien Lespiau
2015-01-17 10:59 ` shuang.he
2015-01-19 15:50 ` Damien Lespiau
2016-06-27 14:40 ` [PATCH v3] drm/i915/gen9: Update i915_drpc_info debugfs for coarse pg & forcewake info akash.goel
2016-08-01 17:48 ` Kamble, Sagar A
2016-08-02 14:09 ` Daniel Vetter
2016-08-04 18:31 ` David Weinehall
2016-08-05 8:24 ` Jani Nikula
2016-08-08 11:10 ` David Weinehall
2016-06-27 14:52 ` ✗ Ro.CI.BAT: warning for " 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=20150119153928.GC30935@strange.ger.corp.intel.com \
--to=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.