aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/perf/builtin-record.c6
-rw-r--r--tools/perf/builtin-sched.c2
2 files changed, 8 insertions, 0 deletions
diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c
index 99a12fe86e9f..79f99dba5be0 100644
--- a/tools/perf/builtin-record.c
+++ b/tools/perf/builtin-record.c
@@ -48,6 +48,7 @@ static int call_graph = 0;
48static int inherit_stat = 0; 48static int inherit_stat = 0;
49static int no_samples = 0; 49static int no_samples = 0;
50static int sample_address = 0; 50static int sample_address = 0;
51static int multiplex = 0;
51 52
52static long samples; 53static long samples;
53static struct timeval last_read; 54static struct timeval last_read;
@@ -485,6 +486,9 @@ try_again:
485 exit(-1); 486 exit(-1);
486 } 487 }
487 488
489 if (multiplex && fd[nr_cpu][counter] != group_fd)
490 ioctl(fd[nr_cpu][counter], PERF_COUNTER_IOC_SET_OUTPUT, group_fd);
491
488 ioctl(fd[nr_cpu][counter], PERF_COUNTER_IOC_ENABLE); 492 ioctl(fd[nr_cpu][counter], PERF_COUNTER_IOC_ENABLE);
489} 493}
490 494
@@ -681,6 +685,8 @@ static const struct option options[] = {
681 "Sample addresses"), 685 "Sample addresses"),
682 OPT_BOOLEAN('n', "no-samples", &no_samples, 686 OPT_BOOLEAN('n', "no-samples", &no_samples,
683 "don't sample"), 687 "don't sample"),
688 OPT_BOOLEAN('M', "multiplex", &multiplex,
689 "multiplex counter output in a single channel"),
684 OPT_END() 690 OPT_END()
685}; 691};
686 692
diff --git a/tools/perf/builtin-sched.c b/tools/perf/builtin-sched.c
index 8db0fd222f80..686af633b35b 100644
--- a/tools/perf/builtin-sched.c
+++ b/tools/perf/builtin-sched.c
@@ -1660,6 +1660,8 @@ static const char *record_args[] = {
1660 "record", 1660 "record",
1661 "-a", 1661 "-a",
1662 "-R", 1662 "-R",
1663 "-M",
1664 "-g",
1663 "-c", "1", 1665 "-c", "1",
1664 "-e", "sched:sched_switch:r", 1666 "-e", "sched:sched_switch:r",
1665 "-e", "sched:sched_stat_wait:r", 1667 "-e", "sched:sched_stat_wait:r",