[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YedcjqmGYekhPgec@google.com>
Date: Wed, 19 Jan 2022 00:34:22 +0000
From: Sean Christopherson <seanjc@...gle.com>
To: Chao Gao <chao.gao@...el.com>
Cc: "Tian, Kevin" <kevin.tian@...el.com>,
"kvm@...r.kernel.org" <kvm@...r.kernel.org>,
"pbonzini@...hat.com" <pbonzini@...hat.com>,
"tglx@...utronix.de" <tglx@...utronix.de>,
Vitaly Kuznetsov <vkuznets@...hat.com>,
Wanpeng Li <wanpengli@...cent.com>,
Jim Mattson <jmattson@...gle.com>,
Joerg Roedel <joro@...tes.org>, Ingo Molnar <mingo@...hat.com>,
Borislav Petkov <bp@...en8.de>,
Dave Hansen <dave.hansen@...ux.intel.com>,
"x86@...nel.org" <x86@...nel.org>,
"H. Peter Anvin" <hpa@...or.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 5/6] KVM: x86: Remove WARN_ON in
kvm_arch_check_processor_compat
On Mon, Jan 17, 2022, Chao Gao wrote:
> On Mon, Jan 17, 2022 at 09:35:04PM +0800, Chao Gao wrote:
> >OK. How about:
> >
> > /*
> > * Compatibility checks are done when loading KVM or in KVM's CPU
> > * hotplug callback. It ensures all online CPUs are compatible before
> > * running any vCPUs. For other cases, compatibility checks are
> > * unnecessary or even problematic. Try to detect improper usages here.
> > */
> > WARN_ON(!irqs_disabled() && !cpu_active(smp_processor_id()));
>
> Sorry. It should be:
> WARN_ON(!irqs_disabled() && cpu_active(smp_processor_id()));
Nice! That's exactly what I was hoping we could do.
Powered by blists - more mailing lists