diff options
author | Alexander Graf <agraf@suse.de> | 2010-07-29 08:47:43 -0400 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2010-10-24 04:50:43 -0400 |
commit | 666e7252a15b7fc4a116e65deaf6da5e4ce660e3 (patch) | |
tree | e7a56f03cb4e181eacd4f481fb3e6e038ad05b82 /arch/powerpc/include/asm/kvm_para.h | |
parent | 96bc451a153297bf1f99ef2d633d512ea349ae7a (diff) |
KVM: PPC: Convert MSR to shared page
One of the most obvious registers to share with the guest directly is the
MSR. The MSR contains the "interrupts enabled" flag which the guest has to
toggle in critical sections.
So in order to bring the overhead of interrupt en- and disabling down, let's
put msr into the shared page. Keep in mind that even though you can fully read
its contents, writing to it doesn't always update all state. There are a few
safe fields that don't require hypervisor interaction. See the documentation
for a list of MSR bits that are safe to be set from inside the guest.
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/powerpc/include/asm/kvm_para.h')
-rw-r--r-- | arch/powerpc/include/asm/kvm_para.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/powerpc/include/asm/kvm_para.h b/arch/powerpc/include/asm/kvm_para.h index 1485ba87a52a..a17dc5229d99 100644 --- a/arch/powerpc/include/asm/kvm_para.h +++ b/arch/powerpc/include/asm/kvm_para.h | |||
@@ -23,6 +23,7 @@ | |||
23 | #include <linux/types.h> | 23 | #include <linux/types.h> |
24 | 24 | ||
25 | struct kvm_vcpu_arch_shared { | 25 | struct kvm_vcpu_arch_shared { |
26 | __u64 msr; | ||
26 | }; | 27 | }; |
27 | 28 | ||
28 | #ifdef __KERNEL__ | 29 | #ifdef __KERNEL__ |