Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Paulo Zanoni <przanoni@gmail.com>
To: intel-gfx@lists.freedesktop.org
Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
Subject: [PATCH 3/3] drm/i915: add i915_ips_status debugfs entry
Date: Mon, 13 May 2013 16:00:10 -0300	[thread overview]
Message-ID: <1368471610-3829-3-git-send-email-przanoni@gmail.com> (raw)
In-Reply-To: <1368471610-3829-1-git-send-email-przanoni@gmail.com>

From: Paulo Zanoni <paulo.r.zanoni@intel.com>

It just prints whether it's supported/enabled/disabled. Feature
requested by the power management team.

Requested-by: Kristen Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
 drivers/gpu/drm/i915/i915_debugfs.c |   20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index a55630a..382ba64 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -1311,6 +1311,25 @@ static int i915_fbc_status(struct seq_file *m, void *unused)
 	return 0;
 }
 
+static int i915_ips_status(struct seq_file *m, void *unused)
+{
+	struct drm_info_node *node = (struct drm_info_node *) m->private;
+	struct drm_device *dev = node->minor->dev;
+	struct drm_i915_private *dev_priv = dev->dev_private;
+
+	if (!IS_ULT(dev)) {
+		seq_printf(m, "not supported\n");
+		return 0;
+	}
+
+	if (I915_READ(IPS_CTL) & IPS_ENABLE)
+		seq_printf(m, "enabled\n");
+	else
+		seq_printf(m, "disabled\n");
+
+	return 0;
+}
+
 static int i915_sr_status(struct seq_file *m, void *unused)
 {
 	struct drm_info_node *node = (struct drm_info_node *) m->private;
@@ -2108,6 +2127,7 @@ static struct drm_info_list i915_debugfs_list[] = {
 	{"i915_ring_freq_table", i915_ring_freq_table, 0},
 	{"i915_gfxec", i915_gfxec, 0},
 	{"i915_fbc_status", i915_fbc_status, 0},
+	{"i915_ips_status", i915_ips_status, 0},
 	{"i915_sr_status", i915_sr_status, 0},
 	{"i915_opregion", i915_opregion, 0},
 	{"i915_gem_framebuffer", i915_gem_framebuffer_info, 0},
-- 
1.7.10.4

  parent reply	other threads:[~2013-05-13 19:01 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-13 19:00 [PATCH 1/3] drm/i915: implement IPS feature Paulo Zanoni
2013-05-13 19:00 ` [PATCH 2/3] drm/i915: add enable_ips module option Paulo Zanoni
2013-05-16 19:56   ` Paulo Zanoni
2013-05-31 16:04     ` Rodrigo Vivi
2013-05-13 19:00 ` Paulo Zanoni [this message]
2013-05-14 17:59   ` [PATCH 3/3] drm/i915: add i915_ips_status debugfs entry Rodrigo Vivi
2013-05-14 17:59     ` Rodrigo Vivi
2013-05-31 16:08   ` Rodrigo Vivi
2013-05-15  7:54 ` [PATCH 1/3] drm/i915: implement IPS feature Chris Wilson
2013-05-16 19:54   ` Paulo Zanoni
2013-05-18  3:18     ` Rodrigo Vivi
2013-05-21  8:41     ` Daniel Vetter
2013-05-23 21:26       ` Paulo Zanoni
2013-05-31 16:07         ` Rodrigo Vivi
2013-05-31 16:30         ` Daniel Vetter
  -- strict thread matches above, loose matches on Subject: below --
2013-05-31 19:33 Paulo Zanoni
2013-05-31 19:33 ` [PATCH 3/3] drm/i915: add i915_ips_status debugfs entry Paulo Zanoni
2013-05-31 19:42   ` Daniel Vetter

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=1368471610-3829-3-git-send-email-przanoni@gmail.com \
    --to=przanoni@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox