Lines Matching refs:regs

107 extern void show_registers(struct pt_regs *regs);
882 static void emulate_load_store_insn(struct pt_regs *regs, in emulate_load_store_insn() argument
895 orig31 = regs->regs[31]; in emulate_load_store_insn()
897 perf_sw_event(PERF_COUNT_SW_EMULATION_FAULTS, 1, regs, 0); in emulate_load_store_insn()
958 compute_return_epc(regs); in emulate_load_store_insn()
959 regs->regs[insn.spec3_format.rt] = value; in emulate_load_store_insn()
971 compute_return_epc(regs); in emulate_load_store_insn()
972 regs->regs[insn.spec3_format.rt] = value; in emulate_load_store_insn()
984 compute_return_epc(regs); in emulate_load_store_insn()
985 regs->regs[insn.spec3_format.rt] = value; in emulate_load_store_insn()
992 compute_return_epc(regs); in emulate_load_store_insn()
993 value = regs->regs[insn.spec3_format.rt]; in emulate_load_store_insn()
1005 compute_return_epc(regs); in emulate_load_store_insn()
1006 value = regs->regs[insn.spec3_format.rt]; in emulate_load_store_insn()
1035 compute_return_epc(regs); in emulate_load_store_insn()
1036 regs->regs[insn.i_format.rt] = value; in emulate_load_store_insn()
1054 compute_return_epc(regs); in emulate_load_store_insn()
1055 regs->regs[insn.i_format.rt] = value; in emulate_load_store_insn()
1073 compute_return_epc(regs); in emulate_load_store_insn()
1074 regs->regs[insn.i_format.rt] = value; in emulate_load_store_insn()
1092 compute_return_epc(regs); in emulate_load_store_insn()
1093 regs->regs[insn.i_format.rt] = value; in emulate_load_store_insn()
1115 compute_return_epc(regs); in emulate_load_store_insn()
1116 regs->regs[insn.i_format.rt] = value; in emulate_load_store_insn()
1127 compute_return_epc(regs); in emulate_load_store_insn()
1128 value = regs->regs[insn.i_format.rt]; in emulate_load_store_insn()
1147 compute_return_epc(regs); in emulate_load_store_insn()
1148 value = regs->regs[insn.i_format.rt]; in emulate_load_store_insn()
1175 compute_return_epc(regs); in emulate_load_store_insn()
1176 value = regs->regs[insn.i_format.rt]; in emulate_load_store_insn()
1190 die_if_kernel("Unaligned FP access in kernel code", regs); in emulate_load_store_insn()
1194 res = fpu_emulator_cop1Handler(regs, &current->thread.fpu, 1, in emulate_load_store_insn()
1214 cu2_notifier_call_chain(CU2_LWC2_OP, regs); in emulate_load_store_insn()
1218 cu2_notifier_call_chain(CU2_LDC2_OP, regs); in emulate_load_store_insn()
1222 cu2_notifier_call_chain(CU2_SWC2_OP, regs); in emulate_load_store_insn()
1226 cu2_notifier_call_chain(CU2_SDC2_OP, regs); in emulate_load_store_insn()
1245 regs->cp0_epc = origpc; in emulate_load_store_insn()
1246 regs->regs[31] = orig31; in emulate_load_store_insn()
1248 if (fixup_exception(regs)) in emulate_load_store_insn()
1251 die_if_kernel("Unhandled kernel unaligned access", regs); in emulate_load_store_insn()
1257 die_if_kernel("Unhandled kernel unaligned access", regs); in emulate_load_store_insn()
1264 ("Unhandled kernel unaligned access or invalid instruction", regs); in emulate_load_store_insn()
1274 static void emulate_load_store_microMIPS(struct pt_regs *regs, in emulate_load_store_microMIPS() argument
1290 origpc = regs->cp0_epc; in emulate_load_store_microMIPS()
1291 orig31 = regs->regs[31]; in emulate_load_store_microMIPS()
1298 pc16 = (unsigned short __user *)msk_isa16_mode(regs->cp0_epc); in emulate_load_store_microMIPS()
1301 contpc = regs->cp0_epc + 2; in emulate_load_store_microMIPS()
1308 contpc = regs->cp0_epc + 4; in emulate_load_store_microMIPS()
1329 if (mm_isBranchInstr(regs, mminsn, &contpc)) in emulate_load_store_microMIPS()
1358 regs->regs[reg] = value; in emulate_load_store_microMIPS()
1363 regs->regs[reg + 1] = value; in emulate_load_store_microMIPS()
1374 value = regs->regs[reg]; in emulate_load_store_microMIPS()
1379 value = regs->regs[reg + 1]; in emulate_load_store_microMIPS()
1397 regs->regs[reg] = value; in emulate_load_store_microMIPS()
1402 regs->regs[reg + 1] = value; in emulate_load_store_microMIPS()
1417 value = regs->regs[reg]; in emulate_load_store_microMIPS()
1422 value = regs->regs[reg + 1]; in emulate_load_store_microMIPS()
1451 regs->regs[i] = value; in emulate_load_store_microMIPS()
1458 regs->regs[30] = value; in emulate_load_store_microMIPS()
1464 regs->regs[31] = value; in emulate_load_store_microMIPS()
1484 value = regs->regs[i]; in emulate_load_store_microMIPS()
1491 value = regs->regs[30]; in emulate_load_store_microMIPS()
1498 value = regs->regs[31]; in emulate_load_store_microMIPS()
1527 regs->regs[i] = value; in emulate_load_store_microMIPS()
1534 regs->regs[30] = value; in emulate_load_store_microMIPS()
1540 regs->regs[31] = value; in emulate_load_store_microMIPS()
1565 value = regs->regs[i]; in emulate_load_store_microMIPS()
1572 value = regs->regs[30]; in emulate_load_store_microMIPS()
1579 value = regs->regs[31]; in emulate_load_store_microMIPS()
1621 regs->cp0_epc = origpc; in emulate_load_store_microMIPS()
1622 regs->regs[31] = orig31; in emulate_load_store_microMIPS()
1624 die_if_kernel("Unaligned FP access in kernel code", regs); in emulate_load_store_microMIPS()
1629 res = fpu_emulator_cop1Handler(regs, &current->thread.fpu, 1, in emulate_load_store_microMIPS()
1681 regs->regs[i] = value; in emulate_load_store_microMIPS()
1686 regs->regs[31] = value; in emulate_load_store_microMIPS()
1697 value = regs->regs[i]; in emulate_load_store_microMIPS()
1703 value = regs->regs[31]; in emulate_load_store_microMIPS()
1753 regs->regs[reg] = value; in emulate_load_store_microMIPS()
1763 regs->regs[reg] = value; in emulate_load_store_microMIPS()
1773 regs->regs[reg] = value; in emulate_load_store_microMIPS()
1791 regs->regs[reg] = value; in emulate_load_store_microMIPS()
1813 regs->regs[reg] = value; in emulate_load_store_microMIPS()
1824 value = regs->regs[reg]; in emulate_load_store_microMIPS()
1834 value = regs->regs[reg]; in emulate_load_store_microMIPS()
1852 value = regs->regs[reg]; in emulate_load_store_microMIPS()
1863 regs->cp0_epc = contpc; /* advance or branch */ in emulate_load_store_microMIPS()
1872 regs->cp0_epc = origpc; in emulate_load_store_microMIPS()
1873 regs->regs[31] = orig31; in emulate_load_store_microMIPS()
1875 if (fixup_exception(regs)) in emulate_load_store_microMIPS()
1878 die_if_kernel("Unhandled kernel unaligned access", regs); in emulate_load_store_microMIPS()
1884 die_if_kernel("Unhandled kernel unaligned access", regs); in emulate_load_store_microMIPS()
1891 ("Unhandled kernel unaligned access or invalid instruction", regs); in emulate_load_store_microMIPS()
1895 static void emulate_load_store_MIPS16e(struct pt_regs *regs, void __user * addr) in emulate_load_store_MIPS16e() argument
1905 origpc = regs->cp0_epc; in emulate_load_store_MIPS16e()
1906 orig31 = regs->regs[31]; in emulate_load_store_MIPS16e()
1918 } else if (delay_slot(regs)) { in emulate_load_store_MIPS16e()
1978 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
1979 regs->regs[reg] = value; in emulate_load_store_MIPS16e()
1989 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
1990 regs->regs[reg] = value; in emulate_load_store_MIPS16e()
2002 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
2003 regs->regs[reg] = value; in emulate_load_store_MIPS16e()
2021 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
2022 regs->regs[reg] = value; in emulate_load_store_MIPS16e()
2045 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
2046 regs->regs[reg] = value; in emulate_load_store_MIPS16e()
2057 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
2058 value = regs->regs[reg]; in emulate_load_store_MIPS16e()
2070 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
2071 value = regs->regs[reg]; in emulate_load_store_MIPS16e()
2090 MIPS16e_compute_return_epc(regs, &oldinst); in emulate_load_store_MIPS16e()
2091 value = regs->regs[reg]; in emulate_load_store_MIPS16e()
2117 regs->cp0_epc = origpc; in emulate_load_store_MIPS16e()
2118 regs->regs[31] = orig31; in emulate_load_store_MIPS16e()
2120 if (fixup_exception(regs)) in emulate_load_store_MIPS16e()
2123 die_if_kernel("Unhandled kernel unaligned access", regs); in emulate_load_store_MIPS16e()
2129 die_if_kernel("Unhandled kernel unaligned access", regs); in emulate_load_store_MIPS16e()
2136 ("Unhandled kernel unaligned access or invalid instruction", regs); in emulate_load_store_MIPS16e()
2140 asmlinkage void do_ade(struct pt_regs *regs) in do_ade() argument
2148 1, regs, regs->cp0_badvaddr); in do_ade()
2152 if (regs->cp0_badvaddr == regs->cp0_epc) in do_ade()
2155 if (user_mode(regs) && !test_thread_flag(TIF_FIXADE)) in do_ade()
2168 if (get_isa16_mode(regs->cp0_epc)) { in do_ade()
2173 if (regs->cp0_badvaddr == msk_isa16_mode(regs->cp0_epc)) in do_ade()
2176 show_registers(regs); in do_ade()
2180 if (!user_mode(regs)) in do_ade()
2182 emulate_load_store_microMIPS(regs, in do_ade()
2183 (void __user *)regs->cp0_badvaddr); in do_ade()
2191 if (!user_mode(regs)) in do_ade()
2193 emulate_load_store_MIPS16e(regs, in do_ade()
2194 (void __user *)regs->cp0_badvaddr); in do_ade()
2204 show_registers(regs); in do_ade()
2205 pc = (unsigned int __user *)exception_epc(regs); in do_ade()
2208 if (!user_mode(regs)) in do_ade()
2210 emulate_load_store_insn(regs, (void __user *)regs->cp0_badvaddr, pc); in do_ade()
2216 die_if_kernel("Kernel unaligned instruction access", regs); in do_ade()