From: Elliott Mitchell <ehem+xen@m5p.com>
To: smita.koralahallichannabasappa@amd.com
Cc: linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org,
x86@kernel.org, xen-devel@lists.xenproject.org, rric@kernel.org,
james.morse@arm.com, tony.luck@intel.com, yazen.ghannam@amd.com
Subject: [PATCH] Revert "EDAC/mce_amd: Do not load edac_mce_amd module on guests"
Date: Thu, 7 Sep 2023 20:08:00 -0700 [thread overview]
Message-ID: <ZPqQEHXgmak1LMNh@mattapan.m5p.com> (raw)
In-Reply-To: <20210628172740.245689-1-Smita.KoralahalliChannabasappa@amd.com>
This reverts commit 767f4b620edadac579c9b8b6660761d4285fa6f9.
There are at least 3 valid reasons why a VM may see MCE events/registers.
First, the hypervisor may have a bug. Ideally this should be dealt with
by fixing the hypervisor. Failing that, the hypervisor and versions
effected need to be identified so only they are flagged as buggy.
Second, the Linux kernel may be handling adminstrative duties/hardware
for a hypervisor. In this case, the events need to be processed and
potentially passed back through the hypervisor.
Third, the hypervisor may do full virtualization of MCE events. In such
case, they should be handled normally.
Any of these blanket disabling the functionality is bad. The original
patch was wrong.
---
drivers/edac/mce_amd.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/edac/mce_amd.c b/drivers/edac/mce_amd.c
index 9215c06783df..1b7fccfbb654 100644
--- a/drivers/edac/mce_amd.c
+++ b/drivers/edac/mce_amd.c
@@ -1361,9 +1361,6 @@ static int __init mce_amd_init(void)
c->x86_vendor != X86_VENDOR_HYGON)
return -ENODEV;
- if (cpu_feature_enabled(X86_FEATURE_HYPERVISOR))
- return -ENODEV;
-
if (boot_cpu_has(X86_FEATURE_SMCA)) {
xec_mask = 0x3f;
goto out;
--
(\___(\___(\______ --=> 8-) EHM <=-- ______/)___/)___/)
\BS ( | ehem+sigmsg@m5p.com PGP 87145445 | ) /
\_CS\ | _____ -O #include <stddisclaimer.h> O- _____ | / _/
8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445
next prev parent reply other threads:[~2023-09-08 3:13 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-28 17:27 [PATCH] EDAC/mce_amd: Do not load edac_mce_amd module on guests Smita Koralahalli
2021-07-08 20:41 ` Yazen Ghannam
2021-07-23 18:18 ` Kim Phillips
2021-08-09 10:44 ` Borislav Petkov
2023-09-08 3:08 ` Elliott Mitchell [this message]
2023-09-08 3:59 ` [PATCH] Revert "EDAC/mce_amd: Do not load edac_mce_amd module on guests" Borislav Petkov
2023-09-13 14:36 ` Yazen Ghannam
2023-09-13 15:50 ` Luck, Tony
2023-09-13 16:21 ` Yazen Ghannam
2023-09-14 17:02 ` Elliott Mitchell
2023-09-15 11:56 ` Borislav Petkov
2023-09-21 21:18 ` Elliott Mitchell
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=ZPqQEHXgmak1LMNh@mattapan.m5p.com \
--to=ehem+xen@m5p.com \
--cc=james.morse@arm.com \
--cc=linux-edac@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rric@kernel.org \
--cc=smita.koralahallichannabasappa@amd.com \
--cc=tony.luck@intel.com \
--cc=x86@kernel.org \
--cc=xen-devel@lists.xenproject.org \
--cc=yazen.ghannam@amd.com \
/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