Skip to contentSkip to conversation

KVM: PPC: 44x: Initialize PVR

PATCH New Alexander Graf 1 participant 1 message Oct 4, 2012

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

PATCH 34/56 KVM: PPC: 44x: Initialize PVR

We need to make sure that vcpu->arch.pvr is initialized to a sane value, so let's just take the host PVR.

---
 arch/powerpc/kvm/44x.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/powerpc/kvm/44x.c +1 -0
index 50e7dbc..3d7fd21 100644
@@ -83,6 +83,7 @@ int kvmppc_core_vcpu_setup(struct kvm_vcpu *vcpu)
 		vcpu_44x->shadow_refs[i].gtlb_index = -1;
 
 	vcpu->arch.cpu_type = KVM_CPU_440;
+	vcpu->arch.pvr = mfspr(SPRN_PVR);
 
 	return 0;
 }
Signature · 1 line
1.6.0.2