* [PATCH] KVM: MCE: Fix compiling without CONFIG_X86_MCE
@ 2009-06-09 1:37 Huang Ying
2009-06-10 9:08 ` Avi Kivity
0 siblings, 1 reply; 2+ messages in thread
From: Huang Ying @ 2009-06-09 1:37 UTC (permalink / raw)
To: avi@redhat.com, Andi Kleen, Marcelo Tosatti
Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org
Enclose do_machine_check with #ifdef CONFIG_X86_MCE.
Reported-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Huang Ying <ying.huang@intel.com>
---
arch/x86/kvm/vmx.c | 2 ++
1 file changed, 2 insertions(+)
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -2623,12 +2623,14 @@ static int handle_rmode_exception(struct
*/
static void kvm_machine_check(void)
{
+#ifdef CONFIG_X86_MCE
struct pt_regs regs = {
.cs = 3, /* Fake ring 3 no matter what the guest ran on */
.flags = X86_EFLAGS_IF,
};
do_machine_check(®s, 0);
+#endif
}
static int handle_machine_check(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] KVM: MCE: Fix compiling without CONFIG_X86_MCE
2009-06-09 1:37 [PATCH] KVM: MCE: Fix compiling without CONFIG_X86_MCE Huang Ying
@ 2009-06-10 9:08 ` Avi Kivity
0 siblings, 0 replies; 2+ messages in thread
From: Avi Kivity @ 2009-06-10 9:08 UTC (permalink / raw)
To: Huang Ying
Cc: Andi Kleen, Marcelo Tosatti, linux-kernel@vger.kernel.org,
kvm@vger.kernel.org
Huang Ying wrote:
> Enclose do_machine_check with #ifdef CONFIG_X86_MCE.
>
> Reported-by: Marcelo Tosatti <mtosatti@redhat.com>
> Signed-off-by: Huang Ying <ying.huang@intel.com>
>
>
Applied, thanks.
I would have preferred to select X86_MCE instead, but that doesn't do
anything (need to select X86_MCE_INTEL as well, and that becomes fragile).
--
error compiling committee.c: too many arguments to function
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-06-10 9:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-09 1:37 [PATCH] KVM: MCE: Fix compiling without CONFIG_X86_MCE Huang Ying
2009-06-10 9:08 ` Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox