aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/evsel.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/util/evsel.c')
-rw-r--r--tools/perf/util/evsel.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c
index d7a2b4b9801d..f4f427ce4d64 100644
--- a/tools/perf/util/evsel.c
+++ b/tools/perf/util/evsel.c
@@ -70,6 +70,7 @@ void perf_evsel__config(struct perf_evsel *evsel, struct perf_record_opts *opts,
70 struct perf_event_attr *attr = &evsel->attr; 70 struct perf_event_attr *attr = &evsel->attr;
71 int track = !evsel->idx; /* only the first counter needs these */ 71 int track = !evsel->idx; /* only the first counter needs these */
72 72
73 attr->disabled = 1;
73 attr->sample_id_all = opts->sample_id_all_missing ? 0 : 1; 74 attr->sample_id_all = opts->sample_id_all_missing ? 0 : 1;
74 attr->inherit = !opts->no_inherit; 75 attr->inherit = !opts->no_inherit;
75 attr->read_format = PERF_FORMAT_TOTAL_TIME_ENABLED | 76 attr->read_format = PERF_FORMAT_TOTAL_TIME_ENABLED |
@@ -138,7 +139,6 @@ void perf_evsel__config(struct perf_evsel *evsel, struct perf_record_opts *opts,
138 139
139 if (perf_target__none(&opts->target) && 140 if (perf_target__none(&opts->target) &&
140 (!opts->group || evsel == first)) { 141 (!opts->group || evsel == first)) {
141 attr->disabled = 1;
142 attr->enable_on_exec = 1; 142 attr->enable_on_exec = 1;
143 } 143 }
144} 144}