From: kan.liang@intel.com
To: peterz@infradead.org, acme@kernel.org
Cc: eranian@google.com, ak@linux.intel.com, jolsa@kernel.org,
namhyung@kernel.org, linux-kernel@vger.kernel.org,
Kan Liang <kan.liang@intel.com>
Subject: [PATCH 8/8] perf test: add test case for PERF_SAMPLE_PHYS_ADDR
Date: Wed, 6 Jan 2016 06:04:37 -0500 [thread overview]
Message-ID: <1452078277-15520-8-git-send-email-kan.liang@intel.com> (raw)
In-Reply-To: <1452078277-15520-1-git-send-email-kan.liang@intel.com>
From: Kan Liang <kan.liang@intel.com>
Extend sample-parsing test cases to support new sample type
PERF_SAMPLE_PHYS_ADDR.
Signed-off-by: Kan Liang <kan.liang@intel.com>
---
tools/perf/tests/sample-parsing.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/tools/perf/tests/sample-parsing.c b/tools/perf/tests/sample-parsing.c
index 5f23710..8813fa1 100644
--- a/tools/perf/tests/sample-parsing.c
+++ b/tools/perf/tests/sample-parsing.c
@@ -45,6 +45,9 @@ static bool samples_same(const struct perf_sample *s1,
if (type & PERF_SAMPLE_ADDR)
COMP(addr);
+ if (type & PERF_SAMPLE_PHYS_ADDR)
+ COMP(phys_addr);
+
if (type & PERF_SAMPLE_ID)
COMP(id);
@@ -303,7 +306,7 @@ int test__sample_parsing(int subtest __maybe_unused)
* were added. Please actually update the test rather than just change
* the condition below.
*/
- if (PERF_SAMPLE_MAX > PERF_SAMPLE_REGS_INTR << 1) {
+ if (PERF_SAMPLE_MAX > PERF_SAMPLE_PHYS_ADDR << 1) {
pr_debug("sample format has changed, some new PERF_SAMPLE_ bit was introduced - test needs updating\n");
return -1;
}
--
1.8.3.1
next prev parent reply other threads:[~2016-01-06 18:23 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-06 11:04 [PATCH 1/8] perf: Add PERF_SAMPLE_PHYS_ADDR kan.liang
2016-01-06 11:04 ` [PATCH 2/8] perf tools: add option to record sample physical address kan.liang
2016-01-07 9:56 ` Jiri Olsa
2016-01-06 11:04 ` [PATCH 3/8] perf tools: add sort option phys_daddr kan.liang
2016-01-06 11:04 ` [PATCH 4/8] perf mem: add option phys-data to record physical address kan.liang
2016-01-06 11:04 ` [PATCH 5/8] perf mem: report physical addresses kan.liang
2016-01-07 8:27 ` Jiri Olsa
2016-01-06 11:04 ` [PATCH 6/8] perf mem: dump " kan.liang
2016-01-06 11:04 ` [PATCH 7/8] perf script: support physical addresses in script kan.liang
2016-01-07 9:54 ` Jiri Olsa
2016-01-06 11:04 ` kan.liang [this message]
2016-01-06 19:21 ` [PATCH 1/8] perf: Add PERF_SAMPLE_PHYS_ADDR Stephane Eranian
2016-01-07 8:33 ` Jiri Olsa
2016-01-07 15:55 ` Liang, Kan
2016-01-07 19:31 ` Jiri Olsa
2016-01-07 21:50 ` Stephane Eranian
2016-01-08 21:12 ` Liang, Kan
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=1452078277-15520-8-git-send-email-kan.liang@intel.com \
--to=kan.liang@intel.com \
--cc=acme@kernel.org \
--cc=ak@linux.intel.com \
--cc=eranian@google.com \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.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
Powered by JetHome