Skip to contentSkip to conversation

perf ftrace latency: Remove unnecessary "--" from --use-nsec option

PATCH Applied Namhyung Kim 2 participants 2 messages May 25, 2023 – May 26, 2023 perf events

lore
Share & tools
lore

Namhyung Kim

author maintainer
#0 lore raw

PATCH 1/1 perf ftrace latency: Remove unnecessary "--" from --use-nsec option

The option name should not have the dashes. Current version shows four dashes for the option.

  $ perf ftrace latency -h

Usage: perf ftrace [<options>] [<command>]
or: perf ftrace [<options>] -- [<command>] [<options>]
or: perf ftrace {trace|latency} [<options>] [<command>]
or: perf ftrace {trace|latency} [<options>] -- [<command>] [<options>]

-b, --use-bpf Use BPF to measure function latency
-n, ----use-nsec Use nano-second histogram
-T, --trace-funcs <func>
Show latency of given function

Fixes 84005bb61486 ("perf ftrace latency: Add -n/--use-nsec option")
---
 tools/perf/builtin-ftrace.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tools/perf/builtin-ftrace.c +1 -1
index ad2a9ae041f6..ac2e6c75f912 100644
@@ -1177,7 +1177,7 @@ int cmd_ftrace(int argc, const char **argv)
 	OPT_BOOLEAN('b', "use-bpf", &ftrace.target.use_bpf,
 		    "Use BPF to measure function latency"),
 #endif
-	OPT_BOOLEAN('n', "--use-nsec", &ftrace.use_nsec,
+	OPT_BOOLEAN('n', "use-nsec", &ftrace.use_nsec,
 		    "Use nano-second histogram"),
 	OPT_PARENT(common_options),
 	};
Signature · 1 line
2.41.0.rc0.172.g3f132b7071-goog
maintainer Applied
#1 lore raw

Em Thu, May 25, 2023 at 02:20:38PM -0700, Namhyung Kim escreveu:

Quoted 10 lines

The option name should not have the dashes. Current version shows four dashes for the option.

  $ perf ftrace latency -h

Usage: perf ftrace [<options>] [<command>]
or: perf ftrace [<options>] -- [<command>] [<options>]
or: perf ftrace {trace|latency} [<options>] [<command>]
or: perf ftrace {trace|latency} [<options>] -- [<command>] [<options>]

Quoted 4 lines

-b, --use-bpf Use BPF to measure function latency
-n, ----use-nsec Use nano-second histogram
-T, --trace-funcs <func>
Show latency of given function

Thanks, applied.

- Arnaldo

Quoted 22 lines
Fixes 84005bb61486 ("perf ftrace latency: Add -n/--use-nsec option")
---
 tools/perf/builtin-ftrace.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tools/perf/builtin-ftrace.c +1 -1
index ad2a9ae041f6..ac2e6c75f912 100644
@@ -1177,7 +1177,7 @@ int cmd_ftrace(int argc, const char **argv)
 	OPT_BOOLEAN('b', "use-bpf", &ftrace.target.use_bpf,
 		    "Use BPF to measure function latency"),
 #endif
-	OPT_BOOLEAN('n', "--use-nsec", &ftrace.use_nsec,
+	OPT_BOOLEAN('n', "use-nsec", &ftrace.use_nsec,
 		    "Use nano-second histogram"),
 	OPT_PARENT(common_options),
 	};
Signature · 1 line
2.41.0.rc0.172.g3f132b7071-goog
Signature · 1 line
- Arnaldo