summaryrefslogtreecommitdiff
path: root/tools/perf/util
diff options
context:
space:
mode:
authorJiri Olsa <jolsa@kernel.org>2019-07-21 13:24:26 +0200
committerArnaldo Carvalho de Melo <acme@redhat.com>2019-07-29 18:34:44 -0300
commit9a5edde6d3a6fb26101406534f7a5d09a9fcd362 (patch)
tree702927f7c84e99665632a2fe9ba07645cb8c5ed1 /tools/perf/util
parent4562a7393996bb28bf629277903a561bfefea177 (diff)
downloadlinux-9a5edde6d3a6fb26101406534f7a5d09a9fcd362.tar.gz
linux-9a5edde6d3a6fb26101406534f7a5d09a9fcd362.tar.bz2
linux-9a5edde6d3a6fb26101406534f7a5d09a9fcd362.zip
libperf: Add perf_evlist__add() function
Add the perf_evlist__add() function to add a perf_evsel in a perf_evlist struct. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexey Budankov <alexey.budankov@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: Michael Petlan <mpetlan@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/20190721112506.12306-40-jolsa@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util')
-rw-r--r--tools/perf/util/evlist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c
index f4aa6cf80559..f2b86f49ab8d 100644
--- a/tools/perf/util/evlist.c
+++ b/tools/perf/util/evlist.c
@@ -180,8 +180,8 @@ static void perf_evlist__propagate_maps(struct evlist *evlist)
void evlist__add(struct evlist *evlist, struct evsel *entry)
{
+ perf_evlist__add(&evlist->core, &entry->core);
entry->evlist = evlist;
- list_add_tail(&entry->core.node, &evlist->core.entries);
entry->idx = evlist->nr_entries;
entry->tracking = !entry->idx;