Merge branch 'upstream' of git://git.infradead.org/users/pcmoore/audit
[firefly-linux-kernel-4.4.55.git] / tools / perf / builtin-help.c
index 25d20628212ed4691ad8ca3cc3c432e5dbffcd13..36486eade1ef4f2d30736c99d7471b86d7dd0ada 100644 (file)
@@ -437,7 +437,18 @@ int cmd_help(int argc, const char **argv, const char *prefix __maybe_unused)
                        HELP_FORMAT_INFO),
        OPT_END(),
        };
-       const char * const builtin_help_usage[] = {
+       const char * const builtin_help_subcommands[] = {
+               "buildid-cache", "buildid-list", "diff", "evlist", "help", "list",
+               "record", "report", "bench", "stat", "timechart", "top", "annotate",
+               "script", "sched", "kmem", "lock", "kvm", "test", "inject", "mem", "data",
+#ifdef HAVE_LIBELF_SUPPORT
+               "probe",
+#endif
+#ifdef HAVE_LIBAUDIT_SUPPORT
+               "trace",
+#endif
+       NULL };
+       const char *builtin_help_usage[] = {
                "perf help [--all] [--man|--web|--info] [command]",
                NULL
        };
@@ -448,8 +459,8 @@ int cmd_help(int argc, const char **argv, const char *prefix __maybe_unused)
 
        perf_config(perf_help_config, &help_format);
 
-       argc = parse_options(argc, argv, builtin_help_options,
-                       builtin_help_usage, 0);
+       argc = parse_options_subcommand(argc, argv, builtin_help_options,
+                       builtin_help_subcommands, builtin_help_usage, 0);
 
        if (show_all) {
                printf("\n usage: %s\n\n", perf_usage_string);