2024-03-25 11:38:33

by Yuan, Perry

[permalink] [raw]
Subject: [PATCH v10 1/8] cpufreq: amd-pstate: Document *_limit_* fields in struct amd_cpudata

From: "Gautham R. Shenoy" <[email protected]>

The four fields of struct cpudata namely min_limit_perf,
max_limit_perf, min_limit_freq, max_limit_freq introduced in the
commit febab20caeba("cpufreq/amd-pstate: Fix scaling_min_freq and
scaling_max_freq update") are currently undocumented

Add comments describing these fields

Fixes: febab20caeba("cpufreq/amd-pstate: Fix scaling_min_freq and scaling_max_freq update")
Reviewed-by: Li Meng <[email protected]>
Tested-by: Dhananjay Ugwekar <[email protected]>
Signed-off-by: Gautham R. Shenoy <[email protected]>
Signed-off-by: Perry Yuan <[email protected]>
---
include/linux/amd-pstate.h | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/include/linux/amd-pstate.h b/include/linux/amd-pstate.h
index d21838835abd..212f377d615b 100644
--- a/include/linux/amd-pstate.h
+++ b/include/linux/amd-pstate.h
@@ -49,6 +49,10 @@ struct amd_aperf_mperf {
* @lowest_perf: the absolute lowest performance level of the processor
* @prefcore_ranking: the preferred core ranking, the higher value indicates a higher
* priority.
+ * @min_limit_perf: Cached value of the perf corresponding to policy->min
+ * @max_limit_perf: Cached value of the perf corresponding to policy->max
+ * @min_limit_freq: Cached value of policy->min
+ * @max_limit_freq: Cached value of policy->max
* @max_freq: the frequency that mapped to highest_perf
* @min_freq: the frequency that mapped to lowest_perf
* @nominal_freq: the frequency that mapped to nominal_perf
--
2.34.1



2024-04-15 01:37:37

by Huang Rui

[permalink] [raw]
Subject: Re: [PATCH v10 1/8] cpufreq: amd-pstate: Document *_limit_* fields in struct amd_cpudata

On Mon, Mar 25, 2024 at 11:03:21AM +0800, Yuan, Perry wrote:
> From: "Gautham R. Shenoy" <[email protected]>
>
> The four fields of struct cpudata namely min_limit_perf,
> max_limit_perf, min_limit_freq, max_limit_freq introduced in the
> commit febab20caeba("cpufreq/amd-pstate: Fix scaling_min_freq and
> scaling_max_freq update") are currently undocumented
>
> Add comments describing these fields
>
> Fixes: febab20caeba("cpufreq/amd-pstate: Fix scaling_min_freq and scaling_max_freq update")
> Reviewed-by: Li Meng <[email protected]>
> Tested-by: Dhananjay Ugwekar <[email protected]>
> Signed-off-by: Gautham R. Shenoy <[email protected]>
> Signed-off-by: Perry Yuan <[email protected]>
> ---
> include/linux/amd-pstate.h | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/include/linux/amd-pstate.h b/include/linux/amd-pstate.h
> index d21838835abd..212f377d615b 100644
> --- a/include/linux/amd-pstate.h
> +++ b/include/linux/amd-pstate.h
> @@ -49,6 +49,10 @@ struct amd_aperf_mperf {
> * @lowest_perf: the absolute lowest performance level of the processor
> * @prefcore_ranking: the preferred core ranking, the higher value indicates a higher
> * priority.
> + * @min_limit_perf: Cached value of the perf corresponding to policy->min
> + * @max_limit_perf: Cached value of the perf corresponding to policy->max

I think we should use "performance" instead of "perf" in the comments.

With that fixed, patch is Acked-by: Huang Rui <[email protected]>

Thanks,
Ray

> + * @min_limit_freq: Cached value of policy->min
> + * @max_limit_freq: Cached value of policy->max
> * @max_freq: the frequency that mapped to highest_perf
> * @min_freq: the frequency that mapped to lowest_perf
> * @nominal_freq: the frequency that mapped to nominal_perf
> --
> 2.34.1
>

2024-04-18 09:27:30

by Yuan, Perry

[permalink] [raw]
Subject: RE: [PATCH v10 1/8] cpufreq: amd-pstate: Document *_limit_* fields in struct amd_cpudata

[AMD Official Use Only - General]

> -----Original Message-----
> From: Huang, Ray <[email protected]>
> Sent: Monday, April 15, 2024 9:37 AM
> To: Yuan, Perry <[email protected]>
> Cc: [email protected]; Limonciello, Mario
> <[email protected]>; [email protected]; Shenoy, Gautham
> Ranjal <[email protected]>; Petkov, Borislav
> <[email protected]>; Deucher, Alexander
> <[email protected]>; Huang, Shimmer
> <[email protected]>; [email protected]; Du, Xiaojian
> <[email protected]>; Meng, Li (Jassmine) <[email protected]>; linux-
> [email protected]; [email protected]
> Subject: Re: [PATCH v10 1/8] cpufreq: amd-pstate: Document *_limit_* fields
> in struct amd_cpudata
>
> On Mon, Mar 25, 2024 at 11:03:21AM +0800, Yuan, Perry wrote:
> > From: "Gautham R. Shenoy" <[email protected]>
> >
> > The four fields of struct cpudata namely min_limit_perf,
> > max_limit_perf, min_limit_freq, max_limit_freq introduced in the
> > commit febab20caeba("cpufreq/amd-pstate: Fix scaling_min_freq and
> > scaling_max_freq update") are currently undocumented
> >
> > Add comments describing these fields
> >
> > Fixes: febab20caeba("cpufreq/amd-pstate: Fix scaling_min_freq and
> > scaling_max_freq update")
> > Reviewed-by: Li Meng <[email protected]>
> > Tested-by: Dhananjay Ugwekar <[email protected]>
> > Signed-off-by: Gautham R. Shenoy <[email protected]>
> > Signed-off-by: Perry Yuan <[email protected]>
> > ---
> > include/linux/amd-pstate.h | 4 ++++
> > 1 file changed, 4 insertions(+)
> >
> > diff --git a/include/linux/amd-pstate.h b/include/linux/amd-pstate.h
> > index d21838835abd..212f377d615b 100644
> > --- a/include/linux/amd-pstate.h
> > +++ b/include/linux/amd-pstate.h
> > @@ -49,6 +49,10 @@ struct amd_aperf_mperf {
> > * @lowest_perf: the absolute lowest performance level of the processor
> > * @prefcore_ranking: the preferred core ranking, the higher value indicates
> a higher
> > * priority.
> > + * @min_limit_perf: Cached value of the perf corresponding to
> > + policy->min
> > + * @max_limit_perf: Cached value of the perf corresponding to
> > + policy->max
>
> I think we should use "performance" instead of "perf" in the comments.

The max limit perf should be OK, the perf string is more meaningful for the pstate driver performance level control.
Thanks.


Perry.
>
> With that fixed, patch is Acked-by: Huang Rui <[email protected]>
>
> Thanks,
> Ray

Thanks, will pick up the flag in v11.


>
> > + * @min_limit_freq: Cached value of policy->min
> > + * @max_limit_freq: Cached value of policy->max
> > * @max_freq: the frequency that mapped to highest_perf
> > * @min_freq: the frequency that mapped to lowest_perf
> > * @nominal_freq: the frequency that mapped to nominal_perf
> > --
> > 2.34.1
> >