kvm: powerpc: book3s: pr: Rename KVM_BOOK3S_PR to KVM_BOOK3S_PR_POSSIBLE
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Mon, 7 Oct 2013 16:47:51 +0000 (22:17 +0530)
committerAlexander Graf <agraf@suse.de>
Thu, 17 Oct 2013 13:17:49 +0000 (15:17 +0200)
With later patches supporting PR kvm as a kernel module, the changes
that has to be built into the main kernel binary to enable PR KVM module
is now selected via KVM_BOOK3S_PR_POSSIBLE

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
arch/powerpc/include/asm/exception-64s.h
arch/powerpc/include/asm/kvm_book3s.h
arch/powerpc/include/asm/kvm_book3s_64.h
arch/powerpc/include/asm/kvm_host.h
arch/powerpc/include/asm/paca.h
arch/powerpc/kernel/asm-offsets.c
arch/powerpc/kernel/exceptions-64s.S
arch/powerpc/kvm/Kconfig
arch/powerpc/kvm/trace.h

index 402c1c466509df65244c4cfeb0aa970d4b88f6ca..a22c9854a6338e3e4af8fe2638559bae7f9c4b3d 100644 (file)
@@ -244,7 +244,7 @@ do_kvm_##n:                                                         \
 #define KVM_HANDLER_SKIP(area, h, n)
 #endif
 
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
 #define KVMTEST_PR(n)                  __KVMTEST(n)
 #define KVM_HANDLER_PR(area, h, n)     __KVM_HANDLER(area, h, n)
 #define KVM_HANDLER_PR_SKIP(area, h, n)        __KVM_HANDLER_SKIP(area, h, n)
index 0ec00f4fef91942a57df1359a2445179df1de441..5c07d10e3c41b290855f882f53592c0680411fd7 100644 (file)
@@ -304,7 +304,7 @@ static inline ulong kvmppc_get_fault_dar(struct kvm_vcpu *vcpu)
        return vcpu->arch.fault_dar;
 }
 
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
 
 static inline unsigned long kvmppc_interrupt_offset(struct kvm_vcpu *vcpu)
 {
@@ -339,7 +339,7 @@ static inline bool kvmppc_critical_section(struct kvm_vcpu *vcpu)
 
        return crit;
 }
-#else /* CONFIG_KVM_BOOK3S_PR */
+#else /* CONFIG_KVM_BOOK3S_PR_POSSIBLE */
 
 static inline unsigned long kvmppc_interrupt_offset(struct kvm_vcpu *vcpu)
 {
index 86d638a3b359e1d0f8e03c09c08adafcf9a7aa28..e6ee7fd32d126ecff91b1479adbe65b3bcc32f37 100644 (file)
@@ -20,7 +20,7 @@
 #ifndef __ASM_KVM_BOOK3S_64_H__
 #define __ASM_KVM_BOOK3S_64_H__
 
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
 static inline struct kvmppc_book3s_shadow_vcpu *svcpu_get(struct kvm_vcpu *vcpu)
 {
        preempt_disable();
index 4959ff1b5376317a2da65e122c1db90d2ac92ab3..9e9f689106e26f9dcd43d8b2c0cbfd46eae9426c 100644 (file)
@@ -257,7 +257,7 @@ struct kvm_arch {
        struct kvmppc_vcore *vcores[KVM_MAX_VCORES];
        int hpt_cma_alloc;
 #endif /* CONFIG_KVM_BOOK3S_64_HV */
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
        struct mutex hpt_mutex;
 #endif
 #ifdef CONFIG_PPC_BOOK3S_64
index a5954cebbc5594228c655906da83714eb6c772cd..b6ea9e068c13dd483033a9f8aea2251d45084cac 100644 (file)
@@ -166,7 +166,7 @@ struct paca_struct {
        struct dtl_entry *dtl_curr;     /* pointer corresponding to dtl_ridx */
 
 #ifdef CONFIG_KVM_BOOK3S_HANDLER
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
        /* We use this to store guest state in */
        struct kvmppc_book3s_shadow_vcpu shadow_vcpu;
 #endif
index 95ba8095fc4ae8f4bba8178f133b7af657ff5a1d..29796559c2fb6f90139b1f30f3adbd819b471d98 100644 (file)
@@ -533,7 +533,7 @@ int main(void)
        DEFINE(VCPU_SLB_SIZE, sizeof(struct kvmppc_slb));
 
 #ifdef CONFIG_PPC_BOOK3S_64
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
        DEFINE(PACA_SVCPU, offsetof(struct paca_struct, shadow_vcpu));
 # define SVCPU_FIELD(x, f)     DEFINE(x, offsetof(struct paca_struct, shadow_vcpu.f))
 #else
index 2a273bed1ec87d961ceb6e148f4cbf6539986ac6..3d1c42b03c89cfc3ecfebccd02de7a0bafc7b0e6 100644 (file)
@@ -425,7 +425,7 @@ data_access_check_stab:
        mfspr   r9,SPRN_DSISR
        srdi    r10,r10,60
        rlwimi  r10,r9,16,0x20
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
        lbz     r9,HSTATE_IN_GUEST(r13)
        rlwimi  r10,r9,8,0x300
 #endif
index ffaef2cb101a4ef50c77f1dc58c3cdac1f2da105..d0665f231e6f9696eba101c93d65721650ffd9e0 100644 (file)
@@ -34,7 +34,7 @@ config KVM_BOOK3S_64_HANDLER
        bool
        select KVM_BOOK3S_HANDLER
 
-config KVM_BOOK3S_PR
+config KVM_BOOK3S_PR_POSSIBLE
        bool
        select KVM_MMIO
        select MMU_NOTIFIER
@@ -44,7 +44,7 @@ config KVM_BOOK3S_32
        depends on PPC_BOOK3S_32 && !SMP && !PTE_64BIT
        select KVM
        select KVM_BOOK3S_32_HANDLER
-       select KVM_BOOK3S_PR
+       select KVM_BOOK3S_PR_POSSIBLE
        ---help---
          Support running unmodified book3s_32 guest kernels
          in virtual machines on book3s_32 host processors.
@@ -91,7 +91,7 @@ config KVM_BOOK3S_64_HV
 config KVM_BOOK3S_64_PR
        def_bool y
        depends on KVM_BOOK3S_64 && !KVM_BOOK3S_64_HV
-       select KVM_BOOK3S_PR
+       select KVM_BOOK3S_PR_POSSIBLE
 
 config KVM_BOOKE_HV
        bool
index a088e9a8c103ac6ec58970b4b3f6b6c0125994c6..9e8368edf371783c2aa54ccff573d2946522e9b4 100644 (file)
@@ -94,7 +94,7 @@ TRACE_EVENT(kvm_exit,
                __field(        unsigned long,  pc              )
                __field(        unsigned long,  msr             )
                __field(        unsigned long,  dar             )
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
                __field(        unsigned long,  srr1            )
 #endif
                __field(        unsigned long,  last_inst       )
@@ -105,7 +105,7 @@ TRACE_EVENT(kvm_exit,
                __entry->pc             = kvmppc_get_pc(vcpu);
                __entry->dar            = kvmppc_get_fault_dar(vcpu);
                __entry->msr            = vcpu->arch.shared->msr;
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
                __entry->srr1           = vcpu->arch.shadow_srr1;
 #endif
                __entry->last_inst      = vcpu->arch.last_inst;
@@ -115,7 +115,7 @@ TRACE_EVENT(kvm_exit,
                " | pc=0x%lx"
                " | msr=0x%lx"
                " | dar=0x%lx"
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
                " | srr1=0x%lx"
 #endif
                " | last_inst=0x%lx"
@@ -124,7 +124,7 @@ TRACE_EVENT(kvm_exit,
                __entry->pc,
                __entry->msr,
                __entry->dar,
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
                __entry->srr1,
 #endif
                __entry->last_inst
@@ -236,7 +236,7 @@ TRACE_EVENT(kvm_check_requests,
  *                         Book3S trace points                           *
  *************************************************************************/
 
-#ifdef CONFIG_KVM_BOOK3S_PR
+#ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
 
 TRACE_EVENT(kvm_book3s_reenter,
        TP_PROTO(int r, struct kvm_vcpu *vcpu),