From: Ravi Bangoria <ravi.bangoria@linux.ibm.com>
To: Jordan Niethe <jniethe5@gmail.com>
Cc: Christophe Leroy <christophe.leroy@c-s.fr>,
Ravi Bangoria <ravi.bangoria@linux.ibm.com>,
Michael Neuling <mikey@linux.ibm.com>,
Nicholas Piggin <npiggin@gmail.com>,
maddy@linux.ibm.com, Paul Mackerras <paulus@samba.org>,
naveen.n.rao@linux.vnet.ibm.com,
linuxppc-dev <linuxppc-dev@lists.ozlabs.org>
Subject: Re: [PATCH v2 1/2] powerpc: Introduce POWER10_DD1 feature
Date: Fri, 23 Oct 2020 15:44:15 +0530 [thread overview]
Message-ID: <a5f84290-0343-fed6-6421-dd1b41084335@linux.ibm.com> (raw)
In-Reply-To: <CACzsE9rqopXj37vrOcyM3sisomeYzxbeR6V4o5K3_Y8xqo5hHw@mail.gmail.com>
>>>> +static void __init fixup_cpu_features(void)
>>>> +{
>>>> + unsigned long version = mfspr(SPRN_PVR);
>>>> +
>>>> + if ((version & 0xffffffff) == 0x00800100)
>>>> + cur_cpu_spec->cpu_features |= CPU_FTR_POWER10_DD1;
>>>> +}
>>>> +
>>> I am just wondering why this is needed here, but the same thing is not
>>> done for, say, CPU_FTR_POWER9_DD2_1?
>>
>> When we don't use DT cpu_features (PowerVM / kvm geusts), we call
>> identify_cpu() twice. First with Real PVR which sets "raw" cpu_spec
>> as cur_cpu_spec and then 2nd time with Logical PVR (0x0f...) which
>> (mostly) overwrites the cur_cpu_spec with "architected" mode cpu_spec.
>> I don't see DD version specific entries for "architected" mode in
>> cpu_specs[] for any previous processors. So I've introduced this
>> function to tweak cpu_features.
>>
>> Though, I don't know why we don't have similar thing for
>> CPU_FTR_POWER9_DD2_1. I've to check that.
>>
>>> And should we get a /* Power10 DD 1 */ added to cpu_specs[]?
>>
>> IIUC, we don't need such entry. For PowerVM / kvm guests, we overwrite
>> cpu_spec, so /* Power10 */ "raw" entry is sufficient. And For baremetal,
>> we don't use cpu_specs[] at all.
> I think even for powernv, using dt features can be disabled by the
> cmdline with dt_cpu_ftrs=off, then cpu_specs[] will then be used.
Ok... with dt_cpu_ftrs=off, we seem to be using raw mode cpu_specs[] entry on
baremetal. So yeah, I'll add /* Power10 DD1 */ raw mode entry into cpu_specs[].
Thanks for pointing it out.
-Ravi
prev parent reply other threads:[~2020-10-23 10:16 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-22 3:40 [PATCH v2 1/2] powerpc: Introduce POWER10_DD1 feature Ravi Bangoria
2020-10-22 3:40 ` [PATCH v2 2/2] powerpc/watchpoint: Workaround P10 DD1 issue with VSX-32 byte instructions Ravi Bangoria
2020-10-22 5:11 ` [PATCH v2 1/2] powerpc: Introduce POWER10_DD1 feature Jordan Niethe
2020-10-22 5:33 ` Ravi Bangoria
2020-10-22 6:26 ` Jordan Niethe
2020-10-23 10:14 ` Ravi Bangoria [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=a5f84290-0343-fed6-6421-dd1b41084335@linux.ibm.com \
--to=ravi.bangoria@linux.ibm.com \
--cc=christophe.leroy@c-s.fr \
--cc=jniethe5@gmail.com \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=maddy@linux.ibm.com \
--cc=mikey@linux.ibm.com \
--cc=naveen.n.rao@linux.vnet.ibm.com \
--cc=npiggin@gmail.com \
--cc=paulus@samba.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).