aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/perf/builtin-record.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c
index 771533ced6a8..f573bbb83572 100644
--- a/tools/perf/builtin-record.c
+++ b/tools/perf/builtin-record.c
@@ -244,6 +244,9 @@ static void create_counter(int counter, int cpu, pid_t pid)
244 244
245 attr->sample_type |= PERF_SAMPLE_IP | PERF_SAMPLE_TID; 245 attr->sample_type |= PERF_SAMPLE_IP | PERF_SAMPLE_TID;
246 246
247 if (nr_counters > 1)
248 attr->sample_type |= PERF_SAMPLE_ID;
249
247 if (freq) { 250 if (freq) {
248 attr->sample_type |= PERF_SAMPLE_PERIOD; 251 attr->sample_type |= PERF_SAMPLE_PERIOD;
249 attr->freq = 1; 252 attr->freq = 1;