All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Cooper <andrew.cooper3@citrix.com>
To: "Roger Pau Monné" <roger.pau@citrix.com>
Cc: Xen-devel <xen-devel@lists.xenproject.org>,
	Jan Beulich <jbeulich@suse.com>, Wei Liu <wl@xen.org>
Subject: Re: [PATCH v2] x86/ucode: Refresh raw CPU policy after microcode load
Date: Thu, 4 May 2023 12:00:07 +0100	[thread overview]
Message-ID: <e9e60c7a-2db5-3985-356e-3a039e44d1a1@citrix.com> (raw)
In-Reply-To: <ZFONUdkG2ow9uckX@Air-de-Roger>

On 04/05/2023 11:47 am, Roger Pau Monné wrote:
> On Thu, May 04, 2023 at 11:26:07AM +0100, Andrew Cooper wrote:
>> Loading microcode can cause new features to appear.  This has happened
>> routinely since Spectre/Meltdown, and even the presence of new status bits can
>> sometimes mean the administrator has no further actions to perform.
>>
>> Conversely, loading microcode can occasionally cause features to disappear.
>> As with livepatching, it is very much the administrators responsibility to
>> confirm that a late microcode load is safe on the intended system before
>> rolling it out in production.
>>
>> Refresh the raw CPU policy after late microcode load appears to have done
>> something, so xen-cpuid can reflect the updated state of the system.
>>
>> Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
>> Reviewed-by: Jan Beulich <jbeulich@suse.com>
> Acked-by: Roger Pau Monné <roger.pau@citrix.com>

Thanks.

> I'm not fully sure it's worth calling calculate_raw_cpu_policy() if
> updated != nr_cores, as it's possible the current CPU where the policy
> is regenerated hasn't been updated.

As said previously, updated != nr_cores may exist in principle, but it
is not a corner case we should care about.

If the system really is asymmetric after a late load, then it is
probably not long for the world.  There is nothing Xen can do to recover.


It is awkward that we're not on the BSP when collecting.  I think that
part of the logic didn't survive the rebase over switching to
stop-machine.  I'll add it to the gitlab ticket of minor ucode work,
because it's not the end of the world.

~Andrew


      reply	other threads:[~2023-05-04 11:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-03 18:58 [PATCH] x86/ucode: Refresh raw CPU policy after microcode load Andrew Cooper
2023-05-04  7:08 ` Jan Beulich
2023-05-04  8:08   ` Andrew Cooper
2023-05-04  8:17     ` Jan Beulich
2023-05-04 10:19       ` Andrew Cooper
2023-05-04  8:22     ` Roger Pau Monné
2023-05-04  9:07       ` Jan Beulich
2023-05-04  9:28         ` Andrew Cooper
2023-05-04 10:26 ` [PATCH v2] " Andrew Cooper
2023-05-04 10:47   ` Roger Pau Monné
2023-05-04 11:00     ` Andrew Cooper [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=e9e60c7a-2db5-3985-356e-3a039e44d1a1@citrix.com \
    --to=andrew.cooper3@citrix.com \
    --cc=jbeulich@suse.com \
    --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 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.