All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Roger Pau Monné" <roger.pau@citrix.com>
To: Jan Beulich <jbeulich@suse.com>
Cc: "xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>,
	Andrew Cooper <andrew.cooper3@citrix.com>,
	Teddy Astie <teddy.astie@vates.tech>
Subject: Re: [PATCH] x86/MCE: fail init more gracefully when CPU vendor isn't supported
Date: Fri, 14 Feb 2025 09:37:33 +0100	[thread overview]
Message-ID: <Z68AzZ1wYCwso55r@macbook.local> (raw)
In-Reply-To: <d27c75e2-df05-41b9-84d4-9d3d6443ef1d@suse.com>

On Thu, Feb 13, 2025 at 02:24:53PM +0100, Jan Beulich wrote:
> When mcheck_init() doesn't recognize the CPU vendor, it will undo the
> all-banks allocation, and it will in particular not install the CPU
> notifier. This way APs will pointlessly try to re-establish an
> all-banks allocation, while then falling over NULL pointers due to the
> notifier hot having run and hence not having allocated anything for
           ^ not
> them.
> 
> Prevent both from happening, and additionally delay writing MCG_CTL
> until no errors can occur anymore in mca_cap_init().
> 
> Fixes: 741367e77d6c ("mce: Clean-up mcheck_init handler")
> Fixes: a5e1b534ac6f ("x86: mce cleanup for both Intel and AMD mce logic")
> Fixes: 560cf418c845 ("x86/mcheck: allow varying bank counts per CPU")
> Reported-by: Teddy Astie <teddy.astie@vates.tech>
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Acked-by: Roger Pau Monné <roger.pau@citrix.com>

The relation between the notifier setting up the state and the init
path seems quite convoluted, but that would require a major refactor
of the logic.

Thanks, Roger.


      reply	other threads:[~2025-02-14  8:37 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-13 13:24 [PATCH] x86/MCE: fail init more gracefully when CPU vendor isn't supported Jan Beulich
2025-02-14  8:37 ` Roger Pau Monné [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=Z68AzZ1wYCwso55r@macbook.local \
    --to=roger.pau@citrix.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=jbeulich@suse.com \
    --cc=teddy.astie@vates.tech \
    --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.