All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Beulich <jbeulich@suse.com>
To: Sergiy Kibrik <Sergiy_Kibrik@epam.com>
Cc: "Andrew Cooper" <andrew.cooper3@citrix.com>,
	"Roger Pau Monné" <roger.pau@citrix.com>,
	"Stefano Stabellini" <sstabellini@kernel.org>,
	xen-devel@lists.xenproject.org
Subject: Re: [XEN PATCH v2 2/5] x86/intel: move vmce_has_lmce() routine to header
Date: Mon, 6 May 2024 13:18:09 +0200	[thread overview]
Message-ID: <12d7600c-ccfa-430c-9c62-a2402b9620b8@suse.com> (raw)
In-Reply-To: <e759fc187f2e3f23f42666b2a8461ae851591d50.1714640459.git.Sergiy_Kibrik@epam.com>

On 02.05.2024 11:14, Sergiy Kibrik wrote:
> Moving this function out of mce_intel.c would make it possible to disable
> build of Intel MCE code later on, because the function gets called from
> common x86 code.
> 
> Add internal check for CONFIG_INTEL option, as MCG_LMCE_P bit is currently
> specific to Intel CPUs only.

My previously voiced concern regarding this was not addressed. If ...

> --- a/xen/arch/x86/cpu/mcheck/mce.h
> +++ b/xen/arch/x86/cpu/mcheck/mce.h
> @@ -170,6 +170,11 @@ static inline int mce_bank_msr(const struct vcpu *v, uint32_t msr)
>      return 0;
>  }
>  
> +static inline bool vmce_has_lmce(const struct vcpu *v)
> +{
> +    return IS_ENABLED(CONFIG_INTEL) && v->arch.vmce.mcg_cap & MCG_LMCE_P;

... the IS_ENABLED() indeed is to stay, the & wants parenthesizing.

Jan


  reply	other threads:[~2024-05-06 11:18 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-02  9:10 [XEN PATCH v2 0/5] x86: make Intel/AMD vPMU & MCE support configurable Sergiy Kibrik
2024-05-02  9:12 ` [XEN PATCH v2 1/5] x86/vpmu: separate amd/intel vPMU code Sergiy Kibrik
2024-05-06 11:09   ` Jan Beulich
2024-05-02  9:14 ` [XEN PATCH v2 2/5] x86/intel: move vmce_has_lmce() routine to header Sergiy Kibrik
2024-05-06 11:18   ` Jan Beulich [this message]
2024-05-13  8:23     ` Sergiy Kibrik
2024-05-02  9:16 ` [XEN PATCH v2 3/5] x86/MCE: guard access to Intel/AMD-specific MCA MSRs Sergiy Kibrik
2024-05-06 11:20   ` Jan Beulich
2024-05-02  9:18 ` [XEN PATCH v2 4/5] x86/MCE: guard {intel/amd}_mcheck_init() calls Sergiy Kibrik
2024-05-06 11:22   ` Jan Beulich
2024-05-02  9:21 ` [XEN PATCH v2 5/5] x86/MCE: optional build of AMD/Intel MCE code Sergiy Kibrik
2024-05-06 11:32   ` Jan Beulich
2024-05-13  9:11     ` Sergiy Kibrik
2024-05-14  7:05       ` Jan Beulich

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=12d7600c-ccfa-430c-9c62-a2402b9620b8@suse.com \
    --to=jbeulich@suse.com \
    --cc=Sergiy_Kibrik@epam.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=roger.pau@citrix.com \
    --cc=sstabellini@kernel.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.