Re: [PATCH] cpufreq: amd-pstate: Let user know amd-pstate is disabled

From: Kai-Heng Feng
Date: Thu Feb 23 2023 - 01:49:46 EST


On Thu, Feb 23, 2023 at 1:02 PM Mario Limonciello
<mario.limonciello@xxxxxxx> wrote:
>
> On 2/22/23 19:30, Kai-Heng Feng wrote:
> > Commit 202e683df37c ("cpufreq: amd-pstate: add amd-pstate driver
>
> s/Commit/commit/

I think the first character of the sentence still needs to be capitalized?

>
> > parameter for mode selection") changed the driver to be disabled by
> > default, and this can suprise users.
>
> s/suprise/surprise/

Will change.

>
> >
> > Let users know what happened so they can decide what to do next.
> >
> > BugLink: https://bugs.launchpad.net/bugs/2006942
>
> s/BugLink/Link/
>
> BugLink isn't an official tag, you should use "Link".

Will change.

>
> > Signed-off-by: Kai-Heng Feng <kai.heng.feng@xxxxxxxxxxxxx>
> > ---
> > drivers/cpufreq/amd-pstate.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/cpufreq/amd-pstate.c b/drivers/cpufreq/amd-pstate.c
> > index 45c88894fd8e..305f73f657ed 100644
> > --- a/drivers/cpufreq/amd-pstate.c
> > +++ b/drivers/cpufreq/amd-pstate.c
> > @@ -1263,7 +1263,7 @@ static int __init amd_pstate_init(void)
> > * with amd_pstate=passive or other modes in kernel command line
> > */
> > if (cppc_state == AMD_PSTATE_DISABLE) {
> > - pr_debug("driver load is disabled, boot with specific mode to enable this\n");
> > + pr_info("amd_pstate is disabled, boot with specific mode to enable this\n");
>
> The file uses `pr_fmt` so this will show up as `amd_pstate: amd_state is
> disabled`. That's a bit redundant no?

Will change.

Kai-Heng

>
> > return -ENODEV;
> > }
> >
>