[PATCH 3/3] Register native mce handler as vMCE bounce back point
From: Liu , Jinsong
Date: Thu May 31 2012 - 20:41:00 EST
When xen hypervisor inject vMCE to guest, use native mce handler to handle =
it
Signed-off-by: Ke, Liping <liping.ke@xxxxxxxxx>
Signed-off-by: Jiang, Yunhong <yunhong.jiang@xxxxxxxxx>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@xxxxxxxxxx>
Signed-off-by: Liu, Jinsong <jinsong.liu@xxxxxxxxx>
---
arch/x86/xen/enlighten.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
index ff2d00e..0cb12dd 100644
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -618,8 +618,8 @@ static int cvt_gate_to_trap(int vector, const gate_desc=
*val,
/*
* Look for known traps using IST, and substitute them
* appropriately. The debugger ones are the only ones we care
- * about. Xen will handle faults like double_fault and
- * machine_check, so we should never see them. Warn if
+ * about. Xen will handle faults like double_fault,
+ * so we should never see them. Warn if
* there's an unexpected IST-using fault handler.
*/
if (addr =3D=3D (unsigned long)debug)
@@ -634,7 +634,11 @@ static int cvt_gate_to_trap(int vector, const gate_des=
c *val,
return 0;
#ifdef CONFIG_X86_MCE
} else if (addr =3D=3D (unsigned long)machine_check) {
- return 0;
+ /*
+ * when xen hyeprvisor inject vMCE to guest,
+ * use native mce handler to handle it
+ */
+ ;
#endif
} else {
/* Some other trap using IST? */
--=20
1.7.1
--_002_DE8DF0795D48FD4CA783C40EC82923351FFB7CSHSMSX101ccrcorpi_
Content-Type: application/octet-stream;
name="0003-Register-native-mce-handler-as-vMCE-bounce-back-poin.patch"
Content-Description: 0003-Register-native-mce-handler-as-vMCE-bounce-back-poin.patch
Content-Disposition: attachment;
filename="0003-Register-native-mce-handler-as-vMCE-bounce-back-poin.patch";
size=1662; creation-date="Thu, 31 May 2012 17:10:05 GMT";
modification-date="Fri, 01 Jun 2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JICogdXNlIG5hdGl2ZSBtY2UgaGFuZGxlciB0byBoYW5kbGUgaXQKKwkJICovCisJCTsK
ICNlbmRpZgogCX0gZWxzZSB7CiAJCS8qIFNvbWUgb3RoZXIgdHJhcCB1c2luZyBJU1Q/ICovCi0t
IAoxLjcuMQoK
--_002_DE8DF0795D48FD4CA783C40EC82923351FFB7CSHSMSX101ccrcorpi_--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/