From: Yazen Ghannam <yazen.ghannam@amd.com>
To: Tony W Wang-oc <TonyWWang-oc@zhaoxin.com>
Cc: tglx@linutronix.de, mingo@redhat.com, bp@alien8.de,
dave.hansen@linux.intel.com, x86@kernel.org, hpa@zytor.com,
tony.luck@intel.com, linux-kernel@vger.kernel.org,
linux-edac@vger.kernel.org, CobeChen@zhaoxin.com,
TimGuo@zhaoxin.com, LeoLiu-oc@zhaoxin.com,
Lyle Li <LyleLi@zhaoxin.com>
Subject: Re: [PATCH v3 1/3] x86/mce: Add centaur vendor to support Zhaoxin MCA
Date: Thu, 19 Sep 2024 09:55:18 -0400 [thread overview]
Message-ID: <20240919135518.GA3717@yaz-khff2.amd.com> (raw)
In-Reply-To: <20240918055436.15551-2-TonyWWang-oc@zhaoxin.com>
On Wed, Sep 18, 2024 at 01:54:34PM +0800, Tony W Wang-oc wrote:
> From: Lyle Li <LyleLi@zhaoxin.com>
>
> Zhaoxin consists of two vendors, X86_VENDOR_ZHAOXIN and
> X86_VENDOR_CENTAUR, so add the centaur vendor to support
> Zhaoxin MCA in mce/core.c and mce/intel.c.
>
> Signed-off-by: Lyle Li <LyleLi@zhaoxin.com>
> Signed-off-by: Tony W Wang-oc <TonyWWang-oc@zhaoxin.com>
> ---
> arch/x86/kernel/cpu/mce/core.c | 12 +++++++++---
> arch/x86/kernel/cpu/mce/intel.c | 3 ++-
> 2 files changed, 11 insertions(+), 4 deletions(-)
>
> diff --git a/arch/x86/kernel/cpu/mce/core.c b/arch/x86/kernel/cpu/mce/core.c
> index ad0623b65..7f79d900f 100644
> --- a/arch/x86/kernel/cpu/mce/core.c
> +++ b/arch/x86/kernel/cpu/mce/core.c
> @@ -496,6 +496,7 @@ bool mce_usable_address(struct mce *m)
>
> case X86_VENDOR_INTEL:
> case X86_VENDOR_ZHAOXIN:
> + case X86_VENDOR_CENTAUR:
> return intel_mce_usable_address(m);
>
> default:
> @@ -513,6 +514,7 @@ bool mce_is_memory_error(struct mce *m)
>
> case X86_VENDOR_INTEL:
> case X86_VENDOR_ZHAOXIN:
> + case X86_VENDOR_CENTAUR:
> /*
> * Intel SDM Volume 3B - 15.9.2 Compound Error Codes
> *
> @@ -1247,7 +1249,8 @@ static noinstr bool mce_check_crashing_cpu(void)
>
> mcgstatus = __rdmsr(MSR_IA32_MCG_STATUS);
>
> - if (boot_cpu_data.x86_vendor == X86_VENDOR_ZHAOXIN) {
> + if (boot_cpu_data.x86_vendor == X86_VENDOR_ZHAOXIN ||
> + boot_cpu_data.x86_vendor == X86_VENDOR_CENTAUR) {
> if (mcgstatus & MCG_STATUS_LMCES)
> return false;
> }
> @@ -1521,7 +1524,8 @@ noinstr void do_machine_check(struct pt_regs *regs)
> * on Intel, Zhaoxin only.
> */
> if (m.cpuvendor == X86_VENDOR_INTEL ||
> - m.cpuvendor == X86_VENDOR_ZHAOXIN)
> + m.cpuvendor == X86_VENDOR_ZHAOXIN ||
> + m.cpuvendor == X86_VENDOR_CENTAUR)
> lmce = m.mcgstatus & MCG_STATUS_LMCES;
>
> /*
> @@ -2092,6 +2096,7 @@ static void __mcheck_cpu_clear_vendor(struct cpuinfo_x86 *c)
> break;
>
> case X86_VENDOR_ZHAOXIN:
> + case X86_VENDOR_CENTAUR:
> mce_zhaoxin_feature_clear(c);
> break;
>
> @@ -2401,7 +2406,8 @@ static void vendor_disable_error_reporting(void)
> if (boot_cpu_data.x86_vendor == X86_VENDOR_INTEL ||
> boot_cpu_data.x86_vendor == X86_VENDOR_HYGON ||
> boot_cpu_data.x86_vendor == X86_VENDOR_AMD ||
> - boot_cpu_data.x86_vendor == X86_VENDOR_ZHAOXIN)
> + boot_cpu_data.x86_vendor == X86_VENDOR_ZHAOXIN ||
> + boot_cpu_data.x86_vendor == X86_VENDOR_CENTAUR)
> return;
>
> mce_disable_error_reporting();
At this point, should we even do this? It seems all major vendors want
to *not* disable MCA_CTL after init.
This, and related functions, can be deleted. Unless there's a compelling
reason to keep them.
Thanks,
Yazen
next prev parent reply other threads:[~2024-09-19 13:55 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <2024090910439.3349-1-TonyWWang-oc@zhaoxin.com>
2024-09-10 9:26 ` [PATCH v2 0/3] x86/mce: Add Zhaoxin MCE support Tony W Wang-oc
2024-09-10 9:26 ` [PATCH v2 1/3] x86/mce: Add centaur vendor to support Zhaoxin MCA Tony W Wang-oc
2024-09-10 9:26 ` [PATCH v2 2/3] x86/mce: Add zhaoxin.c " Tony W Wang-oc
2024-09-10 9:26 ` [PATCH v2 3/3] x86/mce: Add CMCI storm switching support for Zhaoxin Tony W Wang-oc
2024-09-18 5:54 ` [PATCH v3 0/3] x86/mce: Add Zhaoxin MCE support Tony W Wang-oc
2024-09-18 5:54 ` [PATCH v3 1/3] x86/mce: Add centaur vendor to support Zhaoxin MCA Tony W Wang-oc
2024-09-19 13:55 ` Yazen Ghannam [this message]
2024-09-20 10:41 ` Tony W Wang-oc
2024-09-18 5:54 ` [PATCH v3 2/3] x86/mce: Add zhaoxin.c " Tony W Wang-oc
2024-09-18 5:54 ` [PATCH v3 3/3] x86/mce: Add CMCI storm switching support for Zhaoxin Tony W Wang-oc
2024-09-19 14:06 ` Yazen Ghannam
2024-09-20 10:42 ` Tony W Wang-oc
2024-09-20 13:23 ` Yazen Ghannam
2024-09-20 9:17 ` Zhuo, Qiuxu
2024-09-20 10:42 ` Tony W Wang-oc
2024-09-20 11:44 ` Zhuo, Qiuxu
2024-09-20 13:36 ` Yazen Ghannam
2024-09-21 5:39 ` Zhuo, Qiuxu
[not found] ` <acf35354-ab97-4441-828f-daf7affa20ac@zhaoxin.com>
2024-09-23 3:23 ` Tony W Wang-oc
2024-09-23 7:33 ` [PATCH v4 0/4] x86/mce: Add Zhaoxin MCE support and remove Tony W Wang-oc
2024-09-23 7:33 ` [PATCH v4 1/4] x86/mce: Add centaur vendor to support Zhaoxin MCA Tony W Wang-oc
2024-10-12 3:34 ` Zhuo, Qiuxu
2024-09-23 7:33 ` [PATCH v4 2/4] x86/mce: Remove functions that disable error reporting Tony W Wang-oc
2024-10-12 5:37 ` Zhuo, Qiuxu
2024-09-23 7:33 ` [PATCH v4 3/4] x86/mce: Add zhaoxin.c to support Zhaoxin MCA Tony W Wang-oc
2024-10-12 6:41 ` Zhuo, Qiuxu
2024-10-12 9:06 ` Tony W Wang-oc
2024-10-12 11:27 ` Zhuo, Qiuxu
2024-09-23 7:33 ` [PATCH v4 4/4] x86/mce: Add CMCI storm switching support for Zhaoxin Tony W Wang-oc
2024-10-12 7:13 ` Zhuo, Qiuxu
2024-10-12 7:56 ` Tony W Wang-oc
2024-10-14 7:53 ` [PATCH v5 0/4] x86/mce: Add Zhaoxin MCE support and remove functions that disable error reporting Tony W Wang-oc
2024-10-14 7:53 ` [PATCH v5 1/4] x86/mce: Add Centaur vendor to support Zhaoxin MCA Tony W Wang-oc
2024-10-14 7:53 ` [PATCH v5 2/4] x86/mce: Remove functions that disable error reporting Tony W Wang-oc
2024-10-14 7:53 ` [PATCH v5 3/4] x86/mce: Add zhaoxin.c to support Zhaoxin MCA Tony W Wang-oc
2024-10-14 7:53 ` [PATCH v5 4/4] x86/mce: Add CMCI storm switching support for Zhaoxin Tony W Wang-oc
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=20240919135518.GA3717@yaz-khff2.amd.com \
--to=yazen.ghannam@amd.com \
--cc=CobeChen@zhaoxin.com \
--cc=LeoLiu-oc@zhaoxin.com \
--cc=LyleLi@zhaoxin.com \
--cc=TimGuo@zhaoxin.com \
--cc=TonyWWang-oc@zhaoxin.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=hpa@zytor.com \
--cc=linux-edac@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=tglx@linutronix.de \
--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®