Lines Matching refs:msr
125 unsigned long msr = regs->msr; in __unsafe_setup_sigcontext() local
142 msr |= MSR_VEC; in __unsafe_setup_sigcontext()
158 msr &= ~MSR_VSX; in __unsafe_setup_sigcontext()
171 msr |= MSR_VSX; in __unsafe_setup_sigcontext()
176 unsafe_put_user(msr, &sc->gp_regs[PT_MSR], efault_out); in __unsafe_setup_sigcontext()
205 unsigned long msr) in setup_tm_sigcontexts() argument
224 BUG_ON(!MSR_TM_ACTIVE(msr)); in setup_tm_sigcontexts()
232 msr |= tsk->thread.ckpt_regs.msr & (MSR_FP | MSR_VEC | MSR_VSX); in setup_tm_sigcontexts()
246 if (msr & MSR_VEC) in setup_tm_sigcontexts()
258 msr |= MSR_VEC; in setup_tm_sigcontexts()
266 if (msr & MSR_VEC) in setup_tm_sigcontexts()
280 if (msr & MSR_FP) in setup_tm_sigcontexts()
297 if (msr & MSR_VSX) in setup_tm_sigcontexts()
305 msr |= MSR_VSX; in setup_tm_sigcontexts()
314 err |= __put_user(msr, &tm_sc->gp_regs[PT_MSR]); in setup_tm_sigcontexts()
315 err |= __put_user(msr, &sc->gp_regs[PT_MSR]); in setup_tm_sigcontexts()
339 unsigned long msr; in __unsafe_restore_sigcontext() local
355 unsafe_get_user(msr, &sc->gp_regs[PT_MSR], efault_out); in __unsafe_restore_sigcontext()
357 regs_set_return_msr(regs, (regs->msr & ~MSR_LE) | (msr & MSR_LE)); in __unsafe_restore_sigcontext()
379 regs_set_return_msr(regs, regs->msr & ~(MSR_FP | MSR_FE0 | MSR_FE1 | MSR_VEC | MSR_VSX)); in __unsafe_restore_sigcontext()
386 if (v_regs != NULL && (msr & MSR_VEC) != 0) { in __unsafe_restore_sigcontext()
410 if ((msr & MSR_VSX) != 0) { in __unsafe_restore_sigcontext()
437 unsigned long msr; in restore_tm_sigcontexts() local
465 err |= __get_user(msr, &sc->gp_regs[PT_MSR]); in restore_tm_sigcontexts()
467 if (MSR_TM_RESV(msr)) in restore_tm_sigcontexts()
471 regs_set_return_msr(regs, (regs->msr & ~MSR_LE) | (msr & MSR_LE)); in restore_tm_sigcontexts()
498 regs_set_return_msr(regs, regs->msr & ~(MSR_FP | MSR_FE0 | MSR_FE1 | MSR_VEC | MSR_VSX)); in restore_tm_sigcontexts()
510 if (v_regs != NULL && tm_v_regs != NULL && (msr & MSR_VEC) != 0) { in restore_tm_sigcontexts()
544 if (v_regs && ((msr & MSR_VSX) != 0)) { in restore_tm_sigcontexts()
568 regs_set_return_msr(regs, regs->msr | (msr & MSR_TS_MASK)); in restore_tm_sigcontexts()
586 regs_set_return_msr(regs, regs->msr | MSR_TM); in restore_tm_sigcontexts()
591 msr_check_and_set(msr & (MSR_FP | MSR_VEC)); in restore_tm_sigcontexts()
592 if (msr & MSR_FP) { in restore_tm_sigcontexts()
594 regs_set_return_msr(regs, regs->msr | (MSR_FP | tsk->thread.fpexc_mode)); in restore_tm_sigcontexts()
596 if (msr & MSR_VEC) { in restore_tm_sigcontexts()
598 regs_set_return_msr(regs, regs->msr | MSR_VEC); in restore_tm_sigcontexts()
741 unsigned long msr; in SYSCALL_DEFINE0() local
790 regs_set_return_msr(regs, regs->msr & ~MSR_TS_MASK); in SYSCALL_DEFINE0()
792 if (__get_user(msr, &uc->uc_mcontext.gp_regs[PT_MSR])) in SYSCALL_DEFINE0()
796 if (IS_ENABLED(CONFIG_PPC_TRANSACTIONAL_MEM) && MSR_TM_ACTIVE(msr)) { in SYSCALL_DEFINE0()
823 current->thread.regs->msr & ~MSR_TS_MASK); in SYSCALL_DEFINE0()
857 unsigned long msr = regs->msr; in handle_rt_signal64() local
865 if (!MSR_TM_ACTIVE(msr)) in handle_rt_signal64()
878 if (MSR_TM_ACTIVE(msr)) { in handle_rt_signal64()
891 msr); in handle_rt_signal64()
947 regs_set_return_msr(regs, (regs->msr & ~MSR_LE) | (MSR_KERNEL & MSR_LE)); in handle_rt_signal64()