From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Ingo Molnar <mingo@kernel.org>
Cc: linux-kernel@vger.kernel.org, Kan Liang <kan.liang@intel.com>,
Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: [PATCH 17/27] perf env: Read msr pmu type from header
Date: Mon, 14 Sep 2015 13:38:20 -0300 [thread overview]
Message-ID: <1442248710-2339-18-git-send-email-acme@kernel.org> (raw)
In-Reply-To: <1442248710-2339-1-git-send-email-acme@kernel.org>
From: Kan Liang <kan.liang@intel.com>
Get msr pmu type when processing pmu_mappings
Signed-off-by: Kan Liang <kan.liang@intel.com>
Acked-by: Jiri Olsa <jolsa@kernel.org>
Link: http://lkml.kernel.org/n/tip-3ngei63gepydwxhvytl2wx89@git.kernel.org
[ Fixed it up wrt moving perf_env from header.h ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/env.h | 1 +
| 3 +++
2 files changed, 4 insertions(+)
diff --git a/tools/perf/util/env.h b/tools/perf/util/env.h
index 70124d9a1624..d0d1a9681531 100644
--- a/tools/perf/util/env.h
+++ b/tools/perf/util/env.h
@@ -16,6 +16,7 @@ struct perf_env {
char *cpu_desc;
char *cpuid;
unsigned long long total_mem;
+ unsigned int msr_pmu_type;
int nr_cmdline;
int nr_sibling_cores;
--git a/tools/perf/util/header.c b/tools/perf/util/header.c
index 151b8310ac70..f307b17aa45e 100644
--- a/tools/perf/util/header.c
+++ b/tools/perf/util/header.c
@@ -1787,6 +1787,9 @@ static int process_pmu_mappings(struct perf_file_section *section __maybe_unused
/* include a NULL character at the end */
strbuf_add(&sb, "", 1);
+ if (!strcmp(name, "msr"))
+ ph->env.msr_pmu_type = type;
+
free(name);
pmu_num--;
}
--
2.1.0
next prev parent reply other threads:[~2015-09-14 16:38 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-14 16:38 [GIT PULL 00/27] perf/core2 improvements and fixes Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 01/27] perf tests: Take into account address of each objdump line Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 02/27] perf tests: Make objdump disassemble zero blocks Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 03/27] perf tests: Stop reading if objdump output crossed sections Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 04/27] perf tests: Print objdump/dso buffers if they don't match Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 05/27] tools lib api fs: Make tracing_path_strerror_open message generic Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 06/27] tools lib api fs: Replace debugfs/tracefs objects interface with fs.c Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 07/27] tools lib api fs: Remove debugfs, tracefs and findfs objects Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 08/27] perf tools: Switch to tracing_path interface on appropriate places Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 09/27] perf test: Add entry to test cpu topology Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 10/27] perf tests: Introduce iterator function for tests Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 11/27] perf env: Move perf_env out of header.h and session.c into separate object Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 12/27] perf env: Rename some leftovers from rename to perf_env Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 13/27] perf env: Adopt perf_header__set_cmdline Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 14/27] perf hists browser: Fixup the "cpu" column width calculation Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 15/27] perf evsel: Remove forward declaration of 'struct perf_evlist' Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 16/27] perf tools: Add tools/include into tags directories Arnaldo Carvalho de Melo
2015-09-14 16:38 ` Arnaldo Carvalho de Melo [this message]
2015-09-14 16:38 ` [PATCH 18/27] tools lib api fs: Introduce sysfs__read_{int,ull}() Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 19/27] tools lib api cpu: Introduce cpu.[ch] to obtain cpu related information Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 20/27] perf cpu_map: Use sysfs__read_int in get_{core,socket}_id() Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 21/27] perf env: Introduce read_cpu_topology_map() method Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 22/27] perf machine: Add pointer to sample's environment Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 23/27] perf tools: Add processor socket info to hist_entry and addr_location Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 24/27] perf tools: Introduce new sort type "socket" for the processor socket Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 25/27] perf report: Introduce --socket-filter option Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 26/27] perf hists browser: Zoom in/out for processor socket Arnaldo Carvalho de Melo
2015-09-14 16:38 ` [PATCH 27/27] perf test: Add entry for hists socket filter Arnaldo Carvalho de Melo
2015-09-15 6:53 ` [GIT PULL 00/27] perf/core2 improvements and fixes Ingo Molnar
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=1442248710-2339-18-git-send-email-acme@kernel.org \
--to=acme@kernel.org \
--cc=acme@redhat.com \
--cc=kan.liang@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@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).