From: Ingo Molnar <mingo@kernel.org>
To: Alexander Monakov <amonakov@ispras.ru>
Cc: Huang Rui <ray.huang@amd.com>,
linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
Alex Deucher <alexander.deucher@amd.com>,
Jason Bagavatsingham <jason.bagavatsingham@gmail.com>,
"Pierre-Loup A . Griffais" <pgriffais@valvesoftware.com>,
Nathan Fontenot <nathan.fontenot@amd.com>,
"Rafael J . Wysocki" <rafael.j.wysocki@intel.com>,
Borislav Petkov <bp@suse.de>,
x86@kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH v4] x86, sched: Fix the AMD CPPC maximum perf on some specific generations
Date: Thu, 13 May 2021 00:59:02 +0200 [thread overview]
Message-ID: <YJxdttrorwdlpX33@gmail.com> (raw)
In-Reply-To: <alpine.LNX.2.20.13.2105130130590.10864@monopod.intra.ispras.ru>
* Alexander Monakov <amonakov@ispras.ru> wrote:
> On Sun, 25 Apr 2021, Huang Rui wrote:
>
> > Some AMD Ryzen generations has different calculation method on maximum
> > perf. 255 is not for all asics, some specific generations should use 166
> > as the maximum perf. Otherwise, it will report incorrect frequency value
> > like below:
>
> The commit message says '255', but the code:
>
> > --- a/arch/x86/kernel/cpu/amd.c
> > +++ b/arch/x86/kernel/cpu/amd.c
> > @@ -1170,3 +1170,19 @@ void set_dr_addr_mask(unsigned long mask, int dr)
> > break;
> > }
> > }
> > +
> > +u32 amd_get_highest_perf(void)
> > +{
> > + struct cpuinfo_x86 *c = &boot_cpu_data;
> > +
> > + if (c->x86 == 0x17 && ((c->x86_model >= 0x30 && c->x86_model < 0x40) ||
> > + (c->x86_model >= 0x70 && c->x86_model < 0x80)))
> > + return 166;
> > +
> > + if (c->x86 == 0x19 && ((c->x86_model >= 0x20 && c->x86_model < 0x30) ||
> > + (c->x86_model >= 0x40 && c->x86_model < 0x70)))
> > + return 166;
> > +
> > + return 225;
> > +}
>
> says 225? This is probably a typo? In any case they are out of sync.
>
> Alexander
Ugh - that's indeed a good question ...
Thanks,
Ingo
next prev parent reply other threads:[~2021-05-12 23:21 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-25 7:34 [PATCH v4] x86, sched: Fix the AMD CPPC maximum perf on some specific generations Huang Rui
2021-04-28 17:08 ` Rafael J. Wysocki
2021-05-12 19:15 ` Ingo Molnar
2021-05-12 19:20 ` [tip: sched/urgent] x86, sched: Fix the AMD CPPC maximum performance value on certain AMD Ryzen generations tip-bot2 for Huang Rui
2021-05-12 22:34 ` [PATCH v4] x86, sched: Fix the AMD CPPC maximum perf on some specific generations Alexander Monakov
2021-05-12 22:59 ` Ingo Molnar [this message]
2021-05-13 4:24 ` Huang Rui
2021-05-13 10:12 ` Ingo Molnar
2021-05-13 10:27 ` Huang Rui
2021-05-13 10:39 ` Ingo Molnar
2021-05-13 10:45 ` Huang Rui
2021-05-13 10:43 ` [tip: sched/urgent] x86, sched: Fix the AMD CPPC maximum performance value on certain AMD Ryzen generations tip-bot2 for Huang Rui
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=YJxdttrorwdlpX33@gmail.com \
--to=mingo@kernel.org \
--cc=alexander.deucher@amd.com \
--cc=amonakov@ispras.ru \
--cc=bp@suse.de \
--cc=jason.bagavatsingham@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=nathan.fontenot@amd.com \
--cc=pgriffais@valvesoftware.com \
--cc=rafael.j.wysocki@intel.com \
--cc=ray.huang@amd.com \
--cc=stable@vger.kernel.org \
--cc=x86@kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.