Lines Matching refs:arch
88 if (vcpu->arch.papr_enabled && (level > PRIV_SUPER)) in spr_allowed()
101 memcpy(&vcpu->arch.gpr_tm[0], &vcpu->arch.regs.gpr[0], in kvmppc_copyto_vcpu_tm()
102 sizeof(vcpu->arch.gpr_tm)); in kvmppc_copyto_vcpu_tm()
103 memcpy(&vcpu->arch.fp_tm, &vcpu->arch.fp, in kvmppc_copyto_vcpu_tm()
105 memcpy(&vcpu->arch.vr_tm, &vcpu->arch.vr, in kvmppc_copyto_vcpu_tm()
107 vcpu->arch.ppr_tm = vcpu->arch.ppr; in kvmppc_copyto_vcpu_tm()
108 vcpu->arch.dscr_tm = vcpu->arch.dscr; in kvmppc_copyto_vcpu_tm()
109 vcpu->arch.amr_tm = vcpu->arch.amr; in kvmppc_copyto_vcpu_tm()
110 vcpu->arch.ctr_tm = vcpu->arch.regs.ctr; in kvmppc_copyto_vcpu_tm()
111 vcpu->arch.tar_tm = vcpu->arch.tar; in kvmppc_copyto_vcpu_tm()
112 vcpu->arch.lr_tm = vcpu->arch.regs.link; in kvmppc_copyto_vcpu_tm()
113 vcpu->arch.cr_tm = vcpu->arch.cr; in kvmppc_copyto_vcpu_tm()
114 vcpu->arch.xer_tm = vcpu->arch.regs.xer; in kvmppc_copyto_vcpu_tm()
115 vcpu->arch.vrsave_tm = vcpu->arch.vrsave; in kvmppc_copyto_vcpu_tm()
120 memcpy(&vcpu->arch.regs.gpr[0], &vcpu->arch.gpr_tm[0], in kvmppc_copyfrom_vcpu_tm()
121 sizeof(vcpu->arch.regs.gpr)); in kvmppc_copyfrom_vcpu_tm()
122 memcpy(&vcpu->arch.fp, &vcpu->arch.fp_tm, in kvmppc_copyfrom_vcpu_tm()
124 memcpy(&vcpu->arch.vr, &vcpu->arch.vr_tm, in kvmppc_copyfrom_vcpu_tm()
126 vcpu->arch.ppr = vcpu->arch.ppr_tm; in kvmppc_copyfrom_vcpu_tm()
127 vcpu->arch.dscr = vcpu->arch.dscr_tm; in kvmppc_copyfrom_vcpu_tm()
128 vcpu->arch.amr = vcpu->arch.amr_tm; in kvmppc_copyfrom_vcpu_tm()
129 vcpu->arch.regs.ctr = vcpu->arch.ctr_tm; in kvmppc_copyfrom_vcpu_tm()
130 vcpu->arch.tar = vcpu->arch.tar_tm; in kvmppc_copyfrom_vcpu_tm()
131 vcpu->arch.regs.link = vcpu->arch.lr_tm; in kvmppc_copyfrom_vcpu_tm()
132 vcpu->arch.cr = vcpu->arch.cr_tm; in kvmppc_copyfrom_vcpu_tm()
133 vcpu->arch.regs.xer = vcpu->arch.xer_tm; in kvmppc_copyfrom_vcpu_tm()
134 vcpu->arch.vrsave = vcpu->arch.vrsave_tm; in kvmppc_copyfrom_vcpu_tm()
144 vcpu->arch.cr = (vcpu->arch.cr & ~(CR0_MASK << CR0_SHIFT)) | in kvmppc_emulate_treclaim()
166 vcpu->arch.texasr = texasr; in kvmppc_emulate_treclaim()
167 vcpu->arch.tfiar = kvmppc_get_pc(vcpu); in kvmppc_emulate_treclaim()
169 mtspr(SPRN_TFIAR, vcpu->arch.tfiar); in kvmppc_emulate_treclaim()
179 if (vcpu->arch.shadow_fscr & FSCR_TAR) in kvmppc_emulate_treclaim()
180 mtspr(SPRN_TAR, vcpu->arch.tar); in kvmppc_emulate_treclaim()
223 vcpu->arch.cr = (vcpu->arch.cr & ~(CR0_MASK << CR0_SHIFT)) | in kvmppc_emulate_tabort()
227 vcpu->arch.texasr = mfspr(SPRN_TEXASR); in kvmppc_emulate_tabort()
234 vcpu->arch.texasr &= ~(TEXASR_PR | TEXASR_HV); in kvmppc_emulate_tabort()
236 vcpu->arch.texasr |= TEXASR_PR; in kvmppc_emulate_tabort()
239 vcpu->arch.texasr |= TEXASR_HV; in kvmppc_emulate_tabort()
241 vcpu->arch.tfiar = kvmppc_get_pc(vcpu); in kvmppc_emulate_tabort()
332 if (vcpu->arch.mmu.mfsrin) { in kvmppc_core_emulate_op_pr()
334 sr = vcpu->arch.mmu.mfsrin(vcpu, srnum); in kvmppc_core_emulate_op_pr()
344 if (vcpu->arch.mmu.mfsrin) { in kvmppc_core_emulate_op_pr()
346 sr = vcpu->arch.mmu.mfsrin(vcpu, srnum); in kvmppc_core_emulate_op_pr()
352 vcpu->arch.mmu.mtsrin(vcpu, in kvmppc_core_emulate_op_pr()
357 vcpu->arch.mmu.mtsrin(vcpu, in kvmppc_core_emulate_op_pr()
366 vcpu->arch.mmu.tlbie(vcpu, addr, large); in kvmppc_core_emulate_op_pr()
377 !vcpu->arch.papr_enabled) { in kvmppc_core_emulate_op_pr()
392 vcpu->arch.hcall_needed = 1; in kvmppc_core_emulate_op_pr()
400 if (!vcpu->arch.mmu.slbmte) in kvmppc_core_emulate_op_pr()
403 vcpu->arch.mmu.slbmte(vcpu, in kvmppc_core_emulate_op_pr()
408 if (!vcpu->arch.mmu.slbie) in kvmppc_core_emulate_op_pr()
411 vcpu->arch.mmu.slbie(vcpu, in kvmppc_core_emulate_op_pr()
415 if (!vcpu->arch.mmu.slbia) in kvmppc_core_emulate_op_pr()
418 vcpu->arch.mmu.slbia(vcpu); in kvmppc_core_emulate_op_pr()
421 if (!vcpu->arch.mmu.slbmfee) { in kvmppc_core_emulate_op_pr()
427 t = vcpu->arch.mmu.slbmfee(vcpu, rb_val); in kvmppc_core_emulate_op_pr()
432 if (!vcpu->arch.mmu.slbmfev) { in kvmppc_core_emulate_op_pr()
438 t = vcpu->arch.mmu.slbmfev(vcpu, rb_val); in kvmppc_core_emulate_op_pr()
466 vcpu->arch.fault_dar = vaddr; in kvmppc_core_emulate_op_pr()
475 vcpu->arch.fault_dsisr = dsisr; in kvmppc_core_emulate_op_pr()
497 vcpu->arch.cr = (CR0_TBEGIN_FAILURE | in kvmppc_core_emulate_op_pr()
498 (vcpu->arch.cr & ~(CR0_MASK << CR0_SHIFT))); in kvmppc_core_emulate_op_pr()
500 vcpu->arch.texasr = (TEXASR_FS | TEXASR_EXACT | in kvmppc_core_emulate_op_pr()
505 vcpu->arch.texasr |= TEXASR_ROT; in kvmppc_core_emulate_op_pr()
508 vcpu->arch.texasr |= TEXASR_HV; in kvmppc_core_emulate_op_pr()
510 vcpu->arch.tfhar = kvmppc_get_pc(vcpu) + 4; in kvmppc_core_emulate_op_pr()
511 vcpu->arch.tfiar = kvmppc_get_pc(vcpu); in kvmppc_core_emulate_op_pr()
721 switch (vcpu->arch.pvr) { in kvmppc_core_emulate_mtspr_pr()
731 if (vcpu->arch.hflags & BOOK3S_HFLAG_NATIVE_PS) { in kvmppc_core_emulate_mtspr_pr()
734 vcpu->arch.hflags |= BOOK3S_HFLAG_PAIRED_SINGLE; in kvmppc_core_emulate_mtspr_pr()
737 vcpu->arch.hflags &= ~BOOK3S_HFLAG_PAIRED_SINGLE; in kvmppc_core_emulate_mtspr_pr()
749 if (vcpu->arch.mmu.is_dcbz32(vcpu) && in kvmppc_core_emulate_mtspr_pr()
751 vcpu->arch.hflags |= BOOK3S_HFLAG_DCBZ32; in kvmppc_core_emulate_mtspr_pr()
768 vcpu->arch.bescr = spr_val; in kvmppc_core_emulate_mtspr_pr()
771 vcpu->arch.ebbhr = spr_val; in kvmppc_core_emulate_mtspr_pr()
774 vcpu->arch.ebbrr = spr_val; in kvmppc_core_emulate_mtspr_pr()
917 *spr_val = vcpu->arch.purr; in kvmppc_core_emulate_mfspr_pr()
923 *spr_val = vcpu->arch.spurr; in kvmppc_core_emulate_mfspr_pr()
929 *spr_val = vcpu->arch.ic; in kvmppc_core_emulate_mfspr_pr()
943 *spr_val = vcpu->arch.fscr; in kvmppc_core_emulate_mfspr_pr()
946 *spr_val = vcpu->arch.bescr; in kvmppc_core_emulate_mfspr_pr()
949 *spr_val = vcpu->arch.ebbhr; in kvmppc_core_emulate_mfspr_pr()
952 *spr_val = vcpu->arch.ebbrr; in kvmppc_core_emulate_mfspr_pr()
1037 return vcpu->arch.fault_dar; in kvmppc_alignment_dar()