summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kvm/e500.c
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2010-05-03 05:28:58 +0200
committerHerbert Xu <herbert@gondor.apana.org.au>2010-05-03 05:28:58 +0200
commitdf2071bd081408318d659cd14a9cf6ff23d874c9 (patch)
treeb31291b5fd4b9f84c629833afbfaa8d431857475 /arch/powerpc/kvm/e500.c
parentpadata: Dont scale the parallel objects with the cpus (diff)
parentMerge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6 (diff)
downloadlinux-df2071bd081408318d659cd14a9cf6ff23d874c9.tar.xz
linux-df2071bd081408318d659cd14a9cf6ff23d874c9.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'arch/powerpc/kvm/e500.c')
-rw-r--r--arch/powerpc/kvm/e500.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/powerpc/kvm/e500.c b/arch/powerpc/kvm/e500.c
index 64949eef43f1..669a5c5fc7d7 100644
--- a/arch/powerpc/kvm/e500.c
+++ b/arch/powerpc/kvm/e500.c
@@ -13,6 +13,7 @@
*/
#include <linux/kvm_host.h>
+#include <linux/slab.h>
#include <linux/err.h>
#include <asm/reg.h>
@@ -60,6 +61,12 @@ int kvmppc_core_vcpu_setup(struct kvm_vcpu *vcpu)
kvmppc_e500_tlb_setup(vcpu_e500);
+ /* Registers init */
+ vcpu->arch.pvr = mfspr(SPRN_PVR);
+
+ /* Since booke kvm only support one core, update all vcpus' PIR to 0 */
+ vcpu->vcpu_id = 0;
+
return 0;
}