From: Jan Beulich <jbeulich@suse.com>
To: "Roger Pau Monné" <roger.pau@citrix.com>
Cc: Ian Jackson <iwj@xenproject.org>, Wei Liu <wl@xen.org>,
Anthony PERARD <anthony.perard@citrix.com>,
Andrew Cooper <andrew.cooper3@citrix.com>,
xen-devel@lists.xenproject.org
Subject: Re: [PATCH v2 2/2] x86/cpuid: support LFENCE always serializing CPUID bit
Date: Tue, 20 Apr 2021 13:28:45 +0200 [thread overview]
Message-ID: <131cdf88-7942-9cc5-ff7d-ec538055ea9f@suse.com> (raw)
In-Reply-To: <YH6xXeYVTEKsswQp@Air-de-Roger>
On 20.04.2021 12:47, Roger Pau Monné wrote:
> On Tue, Apr 20, 2021 at 12:35:54PM +0200, Jan Beulich wrote:
>> I'd like to give Andrew a day or two more to respond there in case he
>> continues to see an issue, before I commit that with your R-b and this
>> one here. I'll assume you'll subsequently take care of that missing
>> piece then - if not, i.e. if e.g. I should, please let me know.
>
> I think it should be something like the above,
Right (assuming you meant "below).
> in fact I think it
> would be perfectly fine to merge that chunk into your patch?
I'd rather not, so that this change can have its own reasoning in its
description.
Jan
> diff --git a/xen/arch/x86/cpuid.c b/xen/arch/x86/cpuid.c
> index 050cd5713e2..daf501779fe 100644
> --- a/xen/arch/x86/cpuid.c
> +++ b/xen/arch/x86/cpuid.c
> @@ -314,12 +314,9 @@ static void __init calculate_host_policy(void)
>
> *p = raw_cpuid_policy;
>
> - p->basic.max_leaf =
> - min_t(uint32_t, p->basic.max_leaf, ARRAY_SIZE(p->basic.raw) - 1);
> - p->feat.max_subleaf =
> - min_t(uint32_t, p->feat.max_subleaf, ARRAY_SIZE(p->feat.raw) - 1);
> - p->extd.max_leaf = 0x80000000 | min_t(uint32_t, p->extd.max_leaf & 0xffff,
> - ARRAY_SIZE(p->extd.raw) - 1);
> + p->basic.max_leaf = ARRAY_SIZE(p->basic.raw) - 1;
> + p->feat.max_subleaf = ARRAY_SIZE(p->feat.raw) - 1;
> + p->extd.max_leaf = 0x80000000 | ARRAY_SIZE(p->extd.raw) - 1;
>
> cpuid_featureset_to_policy(boot_cpu_data.x86_capability, p);
> recalculate_xstate(p);
>
next prev parent reply other threads:[~2021-04-20 11:29 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-15 14:47 [PATCH v2 0/2] x86/amd: LFENCE always serializing CPUID bit Roger Pau Monne
2021-04-15 14:47 ` [PATCH v2 1/2] x86/amd: split LFENCE dispatch serializing setup logic into helper Roger Pau Monne
2021-04-15 14:47 ` [PATCH v2 2/2] x86/cpuid: support LFENCE always serializing CPUID bit Roger Pau Monne
2021-04-20 10:35 ` Jan Beulich
2021-04-20 10:47 ` Roger Pau Monné
2021-04-20 11:28 ` Jan Beulich [this message]
2021-04-20 12:49 ` Andrew Cooper
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=131cdf88-7942-9cc5-ff7d-ec538055ea9f@suse.com \
--to=jbeulich@suse.com \
--cc=andrew.cooper3@citrix.com \
--cc=anthony.perard@citrix.com \
--cc=iwj@xenproject.org \
--cc=roger.pau@citrix.com \
--cc=wl@xen.org \
--cc=xen-devel@lists.xenproject.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).