Re: [PATCH v5 2/4] cpupower-frequency-info.1: use the proper name of the --perf option
From: Roberto Ricci
Date: Wed Mar 25 2026 - 07:37:33 EST
On 2026-03-24 17:06 -0600, Shuah Khan wrote:
> On 3/24/26 16:39, Roberto Ricci wrote:
> > The cpupower-frequency-info(1) man page describes a '--perf' option.
> > Even though this form is accepted by the program, its proper name is
> > '--performance'.
> >
> > cpufreq-info.c:
> > {"performance", no_argument, NULL, 'c'},
> > [...]
> > --- a/tools/power/cpupower/man/cpupower-frequency-info.1
> > +++ b/tools/power/cpupower/man/cpupower-frequency-info.1
> > @@ -53,7 +53,7 @@ human\-readable output for the \-f, \-w, \-s and \-y parameters.
> > \fB\-n\fR \fB\-\-no-rounding\fR
> > Output frequencies and latencies without rounding off values.
> > .TP
> > -\fB\-c\fR \fB\-\-perf\fR
> > +\fB\-c\fR \fB\-\-performance\fR
>
> I would keep perf and also add performance since --perf and --performance
> work - it is lot easier to type --perf
--perf would still be accepted by the program, whether or not the man
page mentions it. getopt_long() accepts any abbreviation which is not
ambiguous. While I agree that it would be nice to remind users about
abbreviations, why should the man page suggest an arbitrary one out of
the many accepted? And what about the other options (such as
--governors)? Suggesting an abbreviated long form only for --performance
would be inconsistent. The general convention is to list the one-letter
form and the complete long form. Also, if you want to save typing during
interactive use, you can use -c.