mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "tip-bot2 for JP Kobryn" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Aijay Adams <aijay@meta.com>, JP Kobryn <inwardvessel@gmail.com>,
	"Borislav Petkov (AMD)" <bp@alien8.de>,
	Tony Luck <tony.luck@intel.com>,
	Qiuxu Zhuo <qiuxu.zhuo@intel.com>,  <stable@kernel.org>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: ras/urgent] x86/mce: Make sure CMCI banks are cleared during shutdown on Intel
Date: Sat, 28 Jun 2025 11:33:23 -0000	[thread overview]
Message-ID: <175111040376.406.17564735803136963525.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20250627174935.95194-1-inwardvessel@gmail.com>

The following commit has been merged into the ras/urgent branch of tip:

Commit-ID:     30ad231a5029bfa16e46ce868497b1a5cdd3c24d
Gitweb:        https://git.kernel.org/tip/30ad231a5029bfa16e46ce868497b1a5cdd3c24d
Author:        JP Kobryn <inwardvessel@gmail.com>
AuthorDate:    Fri, 27 Jun 2025 10:49:35 -07:00
Committer:     Borislav Petkov (AMD) <bp@alien8.de>
CommitterDate: Sat, 28 Jun 2025 12:45:48 +02:00

x86/mce: Make sure CMCI banks are cleared during shutdown on Intel

CMCI banks are not cleared during shutdown on Intel CPUs. As a side effect,
when a kexec is performed, CPUs coming back online are unable to
rediscover/claim these occupied banks which breaks MCE reporting.

Clear the CPU ownership during shutdown via cmci_clear() so the banks can
be reclaimed and MCE reporting will become functional once more.

  [ bp: Massage commit message. ]

Reported-by: Aijay Adams <aijay@meta.com>
Signed-off-by: JP Kobryn <inwardvessel@gmail.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Tony Luck <tony.luck@intel.com>
Reviewed-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
Cc: <stable@kernel.org>
Link: https://lore.kernel.org/20250627174935.95194-1-inwardvessel@gmail.com
---
 arch/x86/kernel/cpu/mce/intel.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/x86/kernel/cpu/mce/intel.c b/arch/x86/kernel/cpu/mce/intel.c
index efcf21e..9b149b9 100644
--- a/arch/x86/kernel/cpu/mce/intel.c
+++ b/arch/x86/kernel/cpu/mce/intel.c
@@ -478,6 +478,7 @@ void mce_intel_feature_init(struct cpuinfo_x86 *c)
 void mce_intel_feature_clear(struct cpuinfo_x86 *c)
 {
 	intel_clear_lmce();
+	cmci_clear();
 }
 
 bool intel_filter_mce(struct mce *m)

      reply	other threads:[~2025-06-28 11:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-27 17:49 [PATCH tip: x86/bugs v2] x86/mce: make sure cmci banks are cleared during shutdown on intel JP Kobryn
2025-06-28 11:33 ` tip-bot2 for JP Kobryn [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=175111040376.406.17564735803136963525.tip-bot2@tip-bot2 \
    --to=tip-bot2@linutronix.de \
    --cc=aijay@meta.com \
    --cc=bp@alien8.de \
    --cc=inwardvessel@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=qiuxu.zhuo@intel.com \
    --cc=stable@kernel.org \
    --cc=tony.luck@intel.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®