Linux Power Management development
 help / color / mirror / Atom feed
From: K Prateek Nayak <kprateek.nayak@amd.com>
To: Mario Limonciello <mario.limonciello@amd.com>
Cc: Perry Yuan <perry.yuan@amd.com>,
	"open list:X86 ARCHITECTURE (32-BIT AND 64-BIT)"
	<linux-kernel@vger.kernel.org>,
	"open list:CPU FREQUENCY SCALING FRAMEWORK"
	<linux-pm@vger.kernel.org>
Subject: Re: [PATCH] cpufreq/amd-pstate: Loosen requirement on lowest nonlinear frequency != min freq
Date: Tue, 21 Jul 2026 08:21:54 +0530	[thread overview]
Message-ID: <1fcfa283-2233-41da-a3b8-07ef331bd03a@amd.com> (raw)
In-Reply-To: <20260715174318.18235-1-mario.limonciello@amd.com>

Hello Mario,

On 7/15/2026 11:13 PM, Mario Limonciello wrote:
> This requirement was introduced by commit 8f8b42c1fcc93 ("cpufreq:
> amd-pstate: optimize the initial frequency values verification")
> specifically to aid in debugging BIOS issues with invalid _CPC tables
> on some older systems.
> 
> This requirement is too tight for new systems though as some systems
> actually have lowest nonlinear frequency identical to minimum
> frequency.  Allow that combo to work.
> 
> Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>

Since I've not seen anyone complain about this on servers, and neither did
any of the machine I ran this on, feel free to include:

Reviewed-by: K Prateek Nayak <kprateek.nayak@amd.com>
Tested-by: K Prateek Nayak <kprateek.nayak@amd.com>

The "<" check should be good enough to catch any borken BIOS.

> ---
>  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 a74a4cf99d22e..3d72337a33369 100644
> --- a/drivers/cpufreq/amd-pstate.c
> +++ b/drivers/cpufreq/amd-pstate.c
> @@ -1031,7 +1031,7 @@ static int amd_pstate_init_freq(struct amd_cpudata *cpudata)
>  		return -EINVAL;
>  	}
>  
> -	if (lowest_nonlinear_freq <= min_freq || lowest_nonlinear_freq > nominal_freq) {
> +	if (lowest_nonlinear_freq < min_freq || lowest_nonlinear_freq > nominal_freq) {
>  		pr_err("lowest_nonlinear_freq(%d) value is out of range [min_freq(%d), nominal_freq(%d)]\n",
>  			lowest_nonlinear_freq, min_freq, nominal_freq);
>  		return -EINVAL;

-- 
Thanks and Regards,
Prateek


      reply	other threads:[~2026-07-21  2:52 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-15 17:43 [PATCH] cpufreq/amd-pstate: Loosen requirement on lowest nonlinear frequency != min freq Mario Limonciello
2026-07-21  2:51 ` K Prateek Nayak [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1fcfa283-2233-41da-a3b8-07ef331bd03a@amd.com \
    --to=kprateek.nayak@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=mario.limonciello@amd.com \
    --cc=perry.yuan@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox