lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 20 Jun 2012 09:59:06 -0700 From: tip-bot for Arnaldo Carvalho de Melo <acme@...hat.com> To: linux-tip-commits@...r.kernel.org Cc: linux-kernel@...r.kernel.org, eranian@...gle.com, paulus@...ba.org, acme@...hat.com, hpa@...or.com, mingo@...nel.org, peterz@...radead.org, efault@....de, namhyung@...il.com, jolsa@...hat.com, fweisbec@...il.com, dsahern@...il.com, tglx@...utronix.de Subject: [tip:perf/core] perf evsel: Reconstruct raw event with modifiers from perf_event_attr Commit-ID: 6eef3d9c2bcf52b7a3c18e609f5838c007b989a4 Gitweb: http://git.kernel.org/tip/6eef3d9c2bcf52b7a3c18e609f5838c007b989a4 Author: Arnaldo Carvalho de Melo <acme@...hat.com> AuthorDate: Wed, 13 Jun 2012 11:53:37 -0300 Committer: Arnaldo Carvalho de Melo <acme@...hat.com> CommitDate: Tue, 19 Jun 2012 13:06:21 -0300 perf evsel: Reconstruct raw event with modifiers from perf_event_attr I forgot to add the modifiers to raw events too, fix it. Reported-by: Jiri Olsa <jolsa@...hat.com> Cc: David Ahern <dsahern@...il.com> Cc: Frederic Weisbecker <fweisbec@...il.com> Cc: Jiri Olsa <jolsa@...hat.com> Cc: Mike Galbraith <efault@....de> Cc: Namhyung Kim <namhyung@...il.com> Cc: Paul Mackerras <paulus@...ba.org> Cc: Peter Zijlstra <peterz@...radead.org> Cc: Stephane Eranian <eranian@...gle.com> Link: http://lkml.kernel.org/n/tip-pi267j1aqqjti9rqh9qy4g58@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com> --- tools/perf/util/evsel.c | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c index 236bdf2..8f0e9dd 100644 --- a/tools/perf/util/evsel.c +++ b/tools/perf/util/evsel.c @@ -252,6 +252,12 @@ static int perf_evsel__hw_cache_name(struct perf_evsel *evsel, char *bf, size_t return ret + perf_evsel__add_modifiers(evsel, bf + ret, size - ret); } +static int perf_evsel__raw_name(struct perf_evsel *evsel, char *bf, size_t size) +{ + int ret = scnprintf(bf, size, "raw 0x%" PRIx64, evsel->attr.config); + return ret + perf_evsel__add_modifiers(evsel, bf + ret, size - ret); +} + const char *perf_evsel__name(struct perf_evsel *evsel) { char bf[128]; @@ -261,7 +267,7 @@ const char *perf_evsel__name(struct perf_evsel *evsel) switch (evsel->attr.type) { case PERF_TYPE_RAW: - scnprintf(bf, sizeof(bf), "raw 0x%" PRIx64, evsel->attr.config); + perf_evsel__raw_name(evsel, bf, sizeof(bf)); break; case PERF_TYPE_HARDWARE: -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists