Skip to contentSkip to conversation

kvm: (ppc) stub out more functions in order to permit kernel to build

PATCH New Phil Carmody 1 participant 1 message Mar 21, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 kvm: (ppc) stub out more functions in order to permit kernel to build

Build failure mentioned by Stephen Rothwell here:
http://www.mail-archive.com/[email protected]/msg65408.html

Traced to:
commit f445f11eb2cc -"KVM: allow host header to be included even for !CONFIG_KVM"

This patch permits the build to progress by stubbing out the two functions that it fell over on. I have no idea if that's even vaguely appropriate.

This has been .c->.o compile tested only, as g5_defconfig FTB elsewhere.

---
 arch/powerpc/include/asm/kvm_ppc.h |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
arch/powerpc/include/asm/kvm_ppc.h +7 -0
index 44a657a..262d9b7 100644
@@ -20,6 +20,8 @@
 #ifndef __POWERPC_KVM_PPC_H__
 #define __POWERPC_KVM_PPC_H__
 
+#if IS_ENABLED(CONFIG_KVM)
+
 /* This file exists just so we can dereference kvm_vcpu, avoiding nested header
  * dependencies. */
 
@@ -324,4 +326,9 @@ static inline ulong kvmppc_get_ea_indexed(struct kvm_vcpu *vcpu, int ra, int rb)
 	return ea;
 }
 
+#else
+static inline void kvmppc_set_xics_phys(int cpu, unsigned long addr) { return; }
+static inline void kvm_linear_init(void) { return; }
+#endif /* IS_ENABLED(CONFIG_KVM) */
+
 #endif /* __POWERPC_KVM_PPC_H__ */
Signature · 1 line
1.7.2.5