|
@@ -1713,8 +1713,10 @@ int cmd_sched(int argc, const char **argv, const char *prefix __maybe_unused)
|
|
|
"perf sched replay [<options>]",
|
|
|
NULL
|
|
|
};
|
|
|
- const char * const sched_usage[] = {
|
|
|
- "perf sched [<options>] {record|latency|map|replay|script}",
|
|
|
+ const char *const sched_subcommands[] = { "record", "latency", "map",
|
|
|
+ "replay", "script", NULL };
|
|
|
+ const char *sched_usage[] = {
|
|
|
+ NULL,
|
|
|
NULL
|
|
|
};
|
|
|
struct trace_sched_handler lat_ops = {
|
|
@@ -1736,8 +1738,8 @@ int cmd_sched(int argc, const char **argv, const char *prefix __maybe_unused)
|
|
|
for (i = 0; i < ARRAY_SIZE(sched.curr_pid); i++)
|
|
|
sched.curr_pid[i] = -1;
|
|
|
|
|
|
- argc = parse_options(argc, argv, sched_options, sched_usage,
|
|
|
- PARSE_OPT_STOP_AT_NON_OPTION);
|
|
|
+ argc = parse_options_subcommand(argc, argv, sched_options, sched_subcommands,
|
|
|
+ sched_usage, PARSE_OPT_STOP_AT_NON_OPTION);
|
|
|
if (!argc)
|
|
|
usage_with_options(sched_usage, sched_options);
|
|
|
|