linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Reinette Chatre <reinette.chatre@intel.com>
To: tglx@linutronix.de, fenghua.yu@intel.com, tony.luck@intel.com,
	peterz@infradead.org, mingo@redhat.com, acme@kernel.org
Cc: gavin.hindman@intel.com, jithu.joseph@intel.com,
	dave.hansen@intel.com, hpa@zytor.com, x86@kernel.org,
	linux-kernel@vger.kernel.org,
	Reinette Chatre <reinette.chatre@intel.com>
Subject: [PATCH V3 6/6] x86/intel_rdt: Re-enable pseudo-lock measurements
Date: Tue, 11 Sep 2018 10:14:37 -0700	[thread overview]
Message-ID: <b0e79afd7832b5ebe3f2a2ebafc16dcf0b3f77dd.1536685533.git.reinette.chatre@intel.com> (raw)
In-Reply-To: <cover.1536685533.git.reinette.chatre@intel.com>
In-Reply-To: <cover.1536685533.git.reinette.chatre@intel.com>

Commit 4a7a54a55e ("x86/intel_rdt: Disable PMU access") disabled
measurements of pseudo-locked regions because of incorrect usage
of the performance monitoring hardware.

Cache pseudo-locking measurements are now done correctly with the
in-kernel perf API and its use can be re-enabled at this time.

The adjustment to the in-kernel perf API also separated the L2 and L3
measurements that can be triggered separately from user space. The
re-enabling of the measurements is thus not a simple revert of the
original disable in order to accommodate the additional parameter
possible.

Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
---
 arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c b/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c
index 5a294fe080d7..e2bd212f382f 100644
--- a/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c
+++ b/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c
@@ -1226,7 +1226,7 @@ static ssize_t pseudo_lock_measure_trigger(struct file *file,
 	buf[buf_size] = '\0';
 	ret = kstrtoint(buf, 10, &sel);
 	if (ret == 0) {
-		if (sel != 1)
+		if (sel != 1 && sel != 2 && sel != 3)
 			return -EINVAL;
 		ret = debugfs_file_get(file->f_path.dentry);
 		if (ret)
-- 
2.17.0


      parent reply	other threads:[~2018-09-11 17:15 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-11 17:14 [PATCH V3 0/6] perf/core and x86/intel_rdt: Fix lack of coordination with perf Reinette Chatre
2018-09-11 17:14 ` [PATCH V3 1/6] perf/core: Add sanity check to deal with pinned event failure Reinette Chatre
2018-09-11 17:14 ` [PATCH V3 2/6] perf/core: Add helper to obtain performance counter index Reinette Chatre
2018-09-17  8:23   ` Peter Zijlstra
2018-09-17 16:37     ` Reinette Chatre
2018-09-17 23:07       ` Peter Zijlstra
2018-09-18 17:54         ` Reinette Chatre
2018-09-19  9:17           ` Peter Zijlstra
2018-09-11 17:14 ` [PATCH V3 3/6] x86/intel_rdt: Remove local register variables Reinette Chatre
2018-09-11 17:14 ` [PATCH V3 4/6] x86/intel_rdt: Create required perf event attributes Reinette Chatre
2018-09-12  5:49   ` kbuild test robot
2018-09-12  7:20   ` kbuild test robot
2018-09-12 19:54   ` [PATCH V4 " Reinette Chatre
2018-09-11 17:14 ` [PATCH V3 5/6] x86/intel_rdt: Use perf infrastructure for measurements Reinette Chatre
2018-09-17  8:58   ` Peter Zijlstra
2018-09-17 16:54     ` Reinette Chatre
2018-09-11 17:14 ` Reinette Chatre [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=b0e79afd7832b5ebe3f2a2ebafc16dcf0b3f77dd.1536685533.git.reinette.chatre@intel.com \
    --to=reinette.chatre@intel.com \
    --cc=acme@kernel.org \
    --cc=dave.hansen@intel.com \
    --cc=fenghua.yu@intel.com \
    --cc=gavin.hindman@intel.com \
    --cc=hpa@zytor.com \
    --cc=jithu.joseph@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=tony.luck@intel.com \
    --cc=x86@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).