]> git.karo-electronics.de Git - karo-tx-linux.git/commit
KVM: Add VT-x machine check support v4
authorAndi Kleen <andi@firstfloor.org>
Wed, 1 Jul 2009 14:18:45 +0000 (16:18 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 2 Jul 2009 23:49:32 +0000 (16:49 -0700)
commitc45181c66af214e4187664e46460e87d3aefa97a
tree3d26df450f7552e1e0c99a55db48869bc95b0836
parent376c10a25a8b73b90e67d2fa870bfda288fa067d
KVM: Add VT-x machine check support v4

(replaces commit a0861c02a981c943573478ea13b29b1fb958ee5b upstream in a
cleaner way for the 2.6.30 kernel tree)

VT-x needs an explicit MC vector intercept to handle machine checks in
the hypervisor.

It also has a special option to catch machine checks that happen
during VT entry.

Do these interceptions and forward them to the Linux machine check
handler. Make it always look like user space is interrupted because
the machine check handler treats kernel/user space differently.

Thanks to Huang Ying and Jiang Yunhong for help and testing.

Cc: ying.huang@intel.com
v2: Handle machine checks still in interrupt off context
to avoid problems on preemptible kernels.
v3: Handle old style 32bit and make fully standalone

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Cc: Huang Ying <ying.huang@intel.com>
Acked-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
arch/x86/include/asm/kvm_host.h
arch/x86/include/asm/mce.h
arch/x86/include/asm/vmx.h
arch/x86/kernel/cpu/mcheck/mce_32.c
arch/x86/kernel/cpu/mcheck/mce_64.c
arch/x86/kvm/vmx.c