KVM: SVM: Add xsetbv intercept
authorJoerg Roedel <joerg.roedel@amd.com>
Tue, 7 Dec 2010 16:15:06 +0000 (17:15 +0100)
committerAvi Kivity <avi@redhat.com>
Wed, 12 Jan 2011 09:30:49 +0000 (11:30 +0200)
commit81dd35d42c9aef3c1f7ae6ce4cf6a0d382661db5
treeac263e921a56954c8e72668e1bcf5afb82a24bb7
parentd4dbf470096c51cb4785167ea59fdbdea87ccbe4
KVM: SVM: Add xsetbv intercept

This patch implements the xsetbv intercept to the AMD part
of KVM. This makes AVX usable in a save way for the guest on
AVX capable AMD hardware.

The patch is tested by using AVX in the guest and host in
parallel and checking for data corruption. I also used the
KVM xsave unit-tests and they all pass.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
arch/x86/include/asm/svm.h
arch/x86/kvm/svm.c