aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include/asm
diff options
context:
space:
mode:
authorAlexander Graf <agraf@suse.de>2010-03-24 16:48:30 -0400
committerAvi Kivity <avi@redhat.com>2010-05-17 05:17:10 -0400
commitad0a048b096ac819f28667602285453468a8d8f9 (patch)
tree491128ccab48eb277a5cf5919a798b0507da9859 /arch/powerpc/include/asm
parent71fbfd5f38f73515f1516a68fbe04dba198b70f0 (diff)
KVM: PPC: Add OSI hypercall interface
MOL uses its own hypercall interface to call back into userspace when the guest wants to do something. So let's implement that as an exit reason, specify it with a CAP and only really use it when userspace wants us to. The only user of it so far is MOL. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/powerpc/include/asm')
-rw-r--r--arch/powerpc/include/asm/kvm_book3s.h5
-rw-r--r--arch/powerpc/include/asm/kvm_host.h2
2 files changed, 7 insertions, 0 deletions
diff --git a/arch/powerpc/include/asm/kvm_book3s.h b/arch/powerpc/include/asm/kvm_book3s.h
index bea76371dbe1..7e243b2cac72 100644
--- a/arch/powerpc/include/asm/kvm_book3s.h
+++ b/arch/powerpc/include/asm/kvm_book3s.h
@@ -148,6 +148,11 @@ static inline ulong dsisr(void)
148 148
149extern void kvm_return_point(void); 149extern void kvm_return_point(void);
150 150
151/* Magic register values loaded into r3 and r4 before the 'sc' assembly
152 * instruction for the OSI hypercalls */
153#define OSI_SC_MAGIC_R3 0x113724FA
154#define OSI_SC_MAGIC_R4 0x77810F9B
155
151#define INS_DCBZ 0x7c0007ec 156#define INS_DCBZ 0x7c0007ec
152 157
153#endif /* __ASM_KVM_BOOK3S_H__ */ 158#endif /* __ASM_KVM_BOOK3S_H__ */
diff --git a/arch/powerpc/include/asm/kvm_host.h b/arch/powerpc/include/asm/kvm_host.h
index 0ebda67ad6a8..486f1cafd5f7 100644
--- a/arch/powerpc/include/asm/kvm_host.h
+++ b/arch/powerpc/include/asm/kvm_host.h
@@ -273,6 +273,8 @@ struct kvm_vcpu_arch {
273 u8 mmio_sign_extend; 273 u8 mmio_sign_extend;
274 u8 dcr_needed; 274 u8 dcr_needed;
275 u8 dcr_is_write; 275 u8 dcr_is_write;
276 u8 osi_needed;
277 u8 osi_enabled;
276 278
277 u32 cpr0_cfgaddr; /* holds the last set cpr0_cfgaddr */ 279 u32 cpr0_cfgaddr; /* holds the last set cpr0_cfgaddr */
278 280