Skip to contentSkip to conversation

KVM: VMX: Enable machine check support for 32bit targets

PATCH Applied Uros Bizjak 2 participants 2 messages Apr 14, 2020

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 KVM: VMX: Enable machine check support for 32bit targets

There is no reason to limit the use of do_machine_check to 64bit targets. MCE handling works for both target familes.

Cc Paolo Bonzini <[email protected]>
Cc Sean Christopherson <[email protected]>
Fixes a0861c02a981 ("KVM: Add VT-x machine check support")
---
 arch/x86/kvm/vmx/vmx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kvm/vmx/vmx.c +1 -1
index 8959514eaf0f..01330096ff3e 100644
@@ -4572,7 +4572,7 @@ static int handle_rmode_exception(struct kvm_vcpu *vcpu,
  */
 static void kvm_machine_check(void)
 {
-#if defined(CONFIG_X86_MCE) && defined(CONFIG_X86_64)
+#if defined(CONFIG_X86_MCE)
 	struct pt_regs regs = {
 		.cs = 3, /* Fake ring 3 no matter what the guest ran on */
 		.flags = X86_EFLAGS_IF,
Signature · 1 line
2.25.2
maintainer Applied
#1 lore raw
Quoted 18 lines · Uros Bizjak

There is no reason to limit the use of do_machine_check to 64bit targets. MCE handling works for both target familes.

Cc Paolo Bonzini <[email protected]>
Cc Sean Christopherson <[email protected]>
Fixes a0861c02a981 ("KVM: Add VT-x machine check support")
---
 arch/x86/kvm/vmx/vmx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kvm/vmx/vmx.c +0 -0
index 8959514eaf0f..01330096ff3e 100644

arch/x86/kvm/vmx/vmx.c static int handle_rmode_exception(struct kvm_vcpu *vcpu, · line 4578

Quoted 8 lines
arch/x86/kvm/vmx/vmx.c +1 -1
@@ -4572,7 +4572,7 @@ static int handle_rmode_exception(struct kvm_vcpu *vcpu,
  */
 static void kvm_machine_check(void)
 {
-#if defined(CONFIG_X86_MCE) && defined(CONFIG_X86_64)
+#if defined(CONFIG_X86_MCE)
 	struct pt_regs regs = {
 		.cs = 3, /* Fake ring 3 no matter what the guest ran on */
 		.flags = X86_EFLAGS_IF,

Queued, thanks.

Paolo