mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Harry Pan <harry.pan@intel.com>
To: LKML <linux-kernel@vger.kernel.org>, Len Brown <len.brown@intel.com>
Cc: Harry Pan <gs0622@gmail.com>, Harry Pan <harry.pan@intel.com>,
	rafael.j.wysocki@intel.com
Subject: [PATCH] tools/power turbostat: enable BXT DRAM RAPL domain
Date: Mon, 13 Mar 2017 01:22:52 +0800	[thread overview]
Message-ID: <1489339372-1975-1-git-send-email-harry.pan@intel.com> (raw)

Goldmont microarchitecture supports DRAM RAPL domain.

This patch adds relevant flags in probing, such that it enables
DRAM energy profile.

Signed-off-by: Harry Pan <harry.pan@intel.com>

Signed-off-by: Harry Pan <harry.pan@intel.com>
---
 tools/power/x86/turbostat/turbostat.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/tools/power/x86/turbostat/turbostat.c b/tools/power/x86/turbostat/turbostat.c
index 828dccd..d726860 100644
--- a/tools/power/x86/turbostat/turbostat.c
+++ b/tools/power/x86/turbostat/turbostat.c
@@ -3343,11 +3343,14 @@ void rapl_probe(unsigned int family, unsigned int model)
 		break;
 	case INTEL_FAM6_ATOM_GOLDMONT:	/* BXT */
 	case INTEL_FAM6_ATOM_GEMINI_LAKE:
-		do_rapl = RAPL_PKG | RAPL_PKG_POWER_INFO;
-		if (rapl_joules)
+		do_rapl = RAPL_PKG | RAPL_DRAM | RAPL_DRAM_PERF_STATUS | RAPL_PKG_PERF_STATUS | RAPL_PKG_POWER_INFO;
+		if (rapl_joules) {
 			BIC_PRESENT(BIC_Pkg_J);
-		else
+			BIC_PRESENT(BIC_RAM_J);
+		} else {
 			BIC_PRESENT(BIC_PkgWatt);
+			BIC_PRESENT(BIC_RAMWatt);
+		}
 		break;
 	case INTEL_FAM6_SKYLAKE_MOBILE:	/* SKL */
 	case INTEL_FAM6_SKYLAKE_DESKTOP:	/* SKL */
-- 
2.6.6

                 reply	other threads:[~2017-03-12 17:31 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1489339372-1975-1-git-send-email-harry.pan@intel.com \
    --to=harry.pan@intel.com \
    --cc=gs0622@gmail.com \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rafael.j.wysocki@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

Powered by JetHome