KVM: PPC: booke: use vcpu reference from thread_struct
[deliverable/linux.git] / arch / powerpc / kvm / booke_interrupts.S
index bb46b32f9813966724b0d59e8ea0b84923c7eb2c..ca16d57f7686da06bd23971aaff8cf59e5293bc0 100644 (file)
@@ -56,7 +56,8 @@
 _GLOBAL(kvmppc_handler_\ivor_nr)
        /* Get pointer to vcpu and record exit number. */
        mtspr   \scratch , r4
-       mfspr   r4, SPRN_SPRG_RVCPU
+       mfspr   r4, SPRN_SPRG_THREAD
+       lwz     r4, THREAD_KVM_VCPU(r4)
        stw     r3, VCPU_GPR(R3)(r4)
        stw     r5, VCPU_GPR(R5)(r4)
        stw     r6, VCPU_GPR(R6)(r4)
@@ -402,9 +403,6 @@ lightweight_exit:
        lwz     r8, kvmppc_booke_handlers@l(r8)
        mtspr   SPRN_IVPR, r8
 
-       /* Save vcpu pointer for the exception handlers. */
-       mtspr   SPRN_SPRG_WVCPU, r4
-
        lwz     r5, VCPU_SHARED(r4)
 
        /* Can't switch the stack pointer until after IVPR is switched,
This page took 0.024793 seconds and 5 git commands to generate.