/linux-5.19.10/arch/arm64/kernel/ |
D | entry-common.c | 38 static __always_inline void __enter_from_kernel_mode(struct pt_regs *regs) in __enter_from_kernel_mode() argument 40 regs->exit_rcu = false; in __enter_from_kernel_mode() 47 regs->exit_rcu = true; in __enter_from_kernel_mode() 56 static void noinstr enter_from_kernel_mode(struct pt_regs *regs) in enter_from_kernel_mode() argument 58 __enter_from_kernel_mode(regs); in enter_from_kernel_mode() 71 static __always_inline void __exit_to_kernel_mode(struct pt_regs *regs) in __exit_to_kernel_mode() argument 75 if (interrupts_enabled(regs)) { in __exit_to_kernel_mode() 76 if (regs->exit_rcu) { in __exit_to_kernel_mode() 86 if (regs->exit_rcu) in __exit_to_kernel_mode() 91 static void noinstr exit_to_kernel_mode(struct pt_regs *regs) in exit_to_kernel_mode() argument [all …]
|
/linux-5.19.10/arch/openrisc/kernel/ |
D | traps.c | 67 void show_registers(struct pt_regs *regs) in show_registers() argument 73 esp = (unsigned long)(regs->sp); in show_registers() 74 if (user_mode(regs)) in show_registers() 79 smp_processor_id(), regs->pc, regs->sr, regs->sp); in show_registers() 81 0L, regs->gpr[1], regs->gpr[2], regs->gpr[3]); in show_registers() 83 regs->gpr[4], regs->gpr[5], regs->gpr[6], regs->gpr[7]); in show_registers() 85 regs->gpr[8], regs->gpr[9], regs->gpr[10], regs->gpr[11]); in show_registers() 87 regs->gpr[12], regs->gpr[13], regs->gpr[14], regs->gpr[15]); in show_registers() 89 regs->gpr[16], regs->gpr[17], regs->gpr[18], regs->gpr[19]); in show_registers() 91 regs->gpr[20], regs->gpr[21], regs->gpr[22], regs->gpr[23]); in show_registers() [all …]
|
/linux-5.19.10/arch/hexagon/kernel/ |
D | vm_events.c | 22 void show_regs(struct pt_regs *regs) in show_regs() argument 27 regs->restart_r0, regs->syscall_nr); in show_regs() 28 printk(KERN_EMERG "preds: \t\t0x%08lx\n", regs->preds); in show_regs() 30 regs->lc0, regs->sa0, regs->m0); in show_regs() 32 regs->lc1, regs->sa1, regs->m1); in show_regs() 34 regs->gp, regs->ugp, regs->usr); in show_regs() 36 regs->cs0, regs->cs1); in show_regs() 37 printk(KERN_EMERG "r0: \t0x%08lx %08lx %08lx %08lx\n", regs->r00, in show_regs() 38 regs->r01, in show_regs() 39 regs->r02, in show_regs() [all …]
|
/linux-5.19.10/arch/arm64/include/asm/ |
D | ptrace.h | 128 #define compat_usr(x) regs[(x)] 129 #define compat_fp regs[11] 130 #define compat_sp regs[13] 131 #define compat_lr regs[14] 132 #define compat_sp_hyp regs[15] 133 #define compat_lr_irq regs[16] 134 #define compat_sp_irq regs[17] 135 #define compat_lr_svc regs[18] 136 #define compat_sp_svc regs[19] 137 #define compat_lr_abt regs[20] [all …]
|
/linux-5.19.10/arch/csky/kernel/probes/ |
D | simulate-insn.c | 10 static inline bool csky_insn_reg_get_val(struct pt_regs *regs, in csky_insn_reg_get_val() argument 15 *ptr = *(®s->a0 + index); in csky_insn_reg_get_val() 18 *ptr = *(®s->exregs[0] + index - 16); in csky_insn_reg_get_val() 22 *ptr = regs->usp; in csky_insn_reg_get_val() 25 *ptr = regs->lr; in csky_insn_reg_get_val() 28 *ptr = regs->tls; in csky_insn_reg_get_val() 39 static inline bool csky_insn_reg_set_val(struct pt_regs *regs, in csky_insn_reg_set_val() argument 44 *(®s->a0 + index) = val; in csky_insn_reg_set_val() 47 *(®s->exregs[0] + index - 16) = val; in csky_insn_reg_set_val() 51 regs->usp = val; in csky_insn_reg_set_val() [all …]
|
/linux-5.19.10/arch/csky/abiv2/inc/abi/ |
D | elf.h | 7 #define ELF_CORE_COPY_REGS(pr_reg, regs) do { \ argument 8 pr_reg[0] = regs->pc; \ 9 pr_reg[1] = regs->a1; \ 10 pr_reg[2] = regs->a0; \ 11 pr_reg[3] = regs->sr; \ 12 pr_reg[4] = regs->a2; \ 13 pr_reg[5] = regs->a3; \ 14 pr_reg[6] = regs->regs[0]; \ 15 pr_reg[7] = regs->regs[1]; \ 16 pr_reg[8] = regs->regs[2]; \ [all …]
|
/linux-5.19.10/arch/parisc/kernel/ |
D | traps.c | 53 struct pt_regs *regs, const char *loglvl); 79 static void print_gr(const char *level, struct pt_regs *regs) in print_gr() argument 86 printbinary(buf, regs->gr[0], 32); in print_gr() 90 PRINTREGS(level, regs->gr, "r", RFMT, i); in print_gr() 93 static void print_fr(const char *level, struct pt_regs *regs) in print_fr() argument 117 PRINTREGS(level, regs->fr, "fr", FFMT, i); in print_fr() 120 void show_regs(struct pt_regs *regs) in show_regs() argument 126 user = user_mode(regs); in show_regs() 131 print_gr(level, regs); in show_regs() 134 PRINTREGS(level, regs->sr, "sr", RFMT, i); in show_regs() [all …]
|
D | unaligned.c | 106 static int emulate_ldh(struct pt_regs *regs, int toreg) in emulate_ldh() argument 108 unsigned long saddr = regs->ior; in emulate_ldh() 113 regs->isr, regs->ior, toreg); in emulate_ldh() 124 : "r" (saddr), "r" (regs->isr) ); in emulate_ldh() 129 regs->gr[toreg] = val; in emulate_ldh() 134 static int emulate_ldw(struct pt_regs *regs, int toreg, int flop) in emulate_ldw() argument 136 unsigned long saddr = regs->ior; in emulate_ldw() 141 regs->isr, regs->ior, toreg); in emulate_ldw() 156 : "r" (saddr), "r" (regs->isr) ); in emulate_ldw() 161 ((__u32*)(regs->fr))[toreg] = val; in emulate_ldw() [all …]
|
D | kgdb.c | 28 struct pt_regs *regs = args->regs; in __kgdb_notify() local 30 if (kgdb_handle_exception(1, args->signr, cmd, regs)) in __kgdb_notify() 63 void pt_regs_to_gdb_regs(unsigned long *gdb_regs, struct pt_regs *regs) in pt_regs_to_gdb_regs() argument 69 memcpy(gr->gpr, regs->gr, sizeof(gr->gpr)); in pt_regs_to_gdb_regs() 70 memcpy(gr->fr, regs->fr, sizeof(gr->fr)); in pt_regs_to_gdb_regs() 72 gr->sr0 = regs->sr[0]; in pt_regs_to_gdb_regs() 73 gr->sr1 = regs->sr[1]; in pt_regs_to_gdb_regs() 74 gr->sr2 = regs->sr[2]; in pt_regs_to_gdb_regs() 75 gr->sr3 = regs->sr[3]; in pt_regs_to_gdb_regs() 76 gr->sr4 = regs->sr[4]; in pt_regs_to_gdb_regs() [all …]
|
/linux-5.19.10/arch/powerpc/include/asm/ |
D | ptrace.h | 153 extern unsigned long profile_pc(struct pt_regs *regs); 155 #define profile_pc(regs) instruction_pointer(regs) argument 158 long do_syscall_trace_enter(struct pt_regs *regs); 159 void do_syscall_trace_leave(struct pt_regs *regs); 169 static inline void regs_set_return_ip(struct pt_regs *regs, unsigned long ip) in regs_set_return_ip() argument 171 regs->nip = ip; in regs_set_return_ip() 175 static inline void regs_set_return_msr(struct pt_regs *regs, unsigned long msr) in regs_set_return_msr() argument 177 regs->msr = msr; in regs_set_return_msr() 181 static inline void regs_add_return_ip(struct pt_regs *regs, long offset) in regs_add_return_ip() argument 183 regs_set_return_ip(regs, regs->nip + offset); in regs_add_return_ip() [all …]
|
/linux-5.19.10/drivers/media/tuners/ |
D | tda18271-common.c | 57 unsigned char *regs = priv->tda18271_regs; in tda18271_dump_regs() local 60 tda_reg("ID_BYTE = 0x%02x\n", 0xff & regs[R_ID]); in tda18271_dump_regs() 61 tda_reg("THERMO_BYTE = 0x%02x\n", 0xff & regs[R_TM]); in tda18271_dump_regs() 62 tda_reg("POWER_LEVEL_BYTE = 0x%02x\n", 0xff & regs[R_PL]); in tda18271_dump_regs() 63 tda_reg("EASY_PROG_BYTE_1 = 0x%02x\n", 0xff & regs[R_EP1]); in tda18271_dump_regs() 64 tda_reg("EASY_PROG_BYTE_2 = 0x%02x\n", 0xff & regs[R_EP2]); in tda18271_dump_regs() 65 tda_reg("EASY_PROG_BYTE_3 = 0x%02x\n", 0xff & regs[R_EP3]); in tda18271_dump_regs() 66 tda_reg("EASY_PROG_BYTE_4 = 0x%02x\n", 0xff & regs[R_EP4]); in tda18271_dump_regs() 67 tda_reg("EASY_PROG_BYTE_5 = 0x%02x\n", 0xff & regs[R_EP5]); in tda18271_dump_regs() 68 tda_reg("CAL_POST_DIV_BYTE = 0x%02x\n", 0xff & regs[R_CPD]); in tda18271_dump_regs() [all …]
|
/linux-5.19.10/arch/powerpc/kernel/ |
D | traps.c | 73 int (*__debugger)(struct pt_regs *regs) __read_mostly; 74 int (*__debugger_ipi)(struct pt_regs *regs) __read_mostly; 75 int (*__debugger_bpt)(struct pt_regs *regs) __read_mostly; 76 int (*__debugger_sstep)(struct pt_regs *regs) __read_mostly; 77 int (*__debugger_iabr_match)(struct pt_regs *regs) __read_mostly; 78 int (*__debugger_break_match)(struct pt_regs *regs) __read_mostly; 79 int (*__debugger_fault_handler)(struct pt_regs *regs) __read_mostly; 180 static unsigned long oops_begin(struct pt_regs *regs) in oops_begin() argument 206 static void oops_end(unsigned long flags, struct pt_regs *regs, in oops_end() argument 224 if (TRAP(regs) == INTERRUPT_SYSTEM_RESET) in oops_end() [all …]
|
/linux-5.19.10/arch/x86/mm/ |
D | extable.c | 15 static inline unsigned long *pt_regs_nr(struct pt_regs *regs, int nr) in pt_regs_nr() argument 17 int reg_offset = pt_regs_offset(regs, nr); in pt_regs_nr() 23 return (unsigned long *)((unsigned long)regs + reg_offset); in pt_regs_nr() 33 struct pt_regs *regs) in ex_handler_default() argument 36 regs->ax = 0; in ex_handler_default() 38 regs->dx = 0; in ex_handler_default() 40 regs->ip = ex_fixup_addr(e); in ex_handler_default() 45 struct pt_regs *regs, int trapnr) in ex_handler_fault() argument 47 regs->ax = trapnr; in ex_handler_fault() 48 return ex_handler_default(fixup, regs); in ex_handler_fault() [all …]
|
/linux-5.19.10/drivers/media/platform/samsung/s5p-jpeg/ |
D | jpeg-hw-s5p.c | 17 void s5p_jpeg_reset(void __iomem *regs) in s5p_jpeg_reset() argument 21 writel(1, regs + S5P_JPG_SW_RESET); in s5p_jpeg_reset() 22 reg = readl(regs + S5P_JPG_SW_RESET); in s5p_jpeg_reset() 26 reg = readl(regs + S5P_JPG_SW_RESET); in s5p_jpeg_reset() 30 void s5p_jpeg_poweron(void __iomem *regs) in s5p_jpeg_poweron() argument 32 writel(S5P_POWER_ON, regs + S5P_JPGCLKCON); in s5p_jpeg_poweron() 35 void s5p_jpeg_input_raw_mode(void __iomem *regs, unsigned long mode) in s5p_jpeg_input_raw_mode() argument 45 reg = readl(regs + S5P_JPGCMOD); in s5p_jpeg_input_raw_mode() 48 writel(reg, regs + S5P_JPGCMOD); in s5p_jpeg_input_raw_mode() 51 void s5p_jpeg_proc_mode(void __iomem *regs, unsigned long mode) in s5p_jpeg_proc_mode() argument [all …]
|
/linux-5.19.10/arch/mips/kernel/ |
D | mips-r2-to-r6-emul.c | 78 static inline int mipsr6_emul(struct pt_regs *regs, u32 ir) in mipsr6_emul() argument 83 regs->regs[MIPSInst_RT(ir)] = in mipsr6_emul() 84 (s32)regs->regs[MIPSInst_RS(ir)] + in mipsr6_emul() 92 regs->regs[MIPSInst_RT(ir)] = in mipsr6_emul() 93 (s64)regs->regs[MIPSInst_RS(ir)] + in mipsr6_emul() 106 regs->regs[MIPSInst_RD(ir)] = in mipsr6_emul() 107 regs->regs[MIPSInst_RS(ir)] | in mipsr6_emul() 108 regs->regs[MIPSInst_RT(ir)]; in mipsr6_emul() 115 regs->regs[MIPSInst_RD(ir)] = in mipsr6_emul() 116 (s32)(((u32)regs->regs[MIPSInst_RT(ir)]) << in mipsr6_emul() [all …]
|
D | branch.c | 29 int __isa_exception_epc(struct pt_regs *regs) in __isa_exception_epc() argument 32 long epc = regs->cp0_epc; in __isa_exception_epc() 59 int __mm_isBranchInstr(struct pt_regs *regs, struct mm_decoded_insn dec_insn, in __mm_isBranchInstr() argument 79 regs->regs[insn.mm_i_format.rt] = in __mm_isBranchInstr() 80 regs->cp0_epc + in __mm_isBranchInstr() 83 *contpc = regs->regs[insn.mm_i_format.rs]; in __mm_isBranchInstr() 92 regs->regs[31] = regs->cp0_epc + in __mm_isBranchInstr() 97 if ((long)regs->regs[insn.mm_i_format.rs] < 0) in __mm_isBranchInstr() 98 *contpc = regs->cp0_epc + in __mm_isBranchInstr() 102 *contpc = regs->cp0_epc + in __mm_isBranchInstr() [all …]
|
/linux-5.19.10/arch/sh/kernel/ |
D | signal_32.c | 90 struct pt_regs *regs) in save_sigcontext_fpu() argument 108 unlazy_fpu(tsk, regs); in save_sigcontext_fpu() 115 restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc, int *r0_p) in restore_sigcontext() argument 119 #define COPY(x) err |= __get_user(regs->x, &sc->sc_##x) in restore_sigcontext() 120 COPY(regs[1]); in restore_sigcontext() 121 COPY(regs[2]); COPY(regs[3]); in restore_sigcontext() 122 COPY(regs[4]); COPY(regs[5]); in restore_sigcontext() 123 COPY(regs[6]); COPY(regs[7]); in restore_sigcontext() 124 COPY(regs[8]); COPY(regs[9]); in restore_sigcontext() 125 COPY(regs[10]); COPY(regs[11]); in restore_sigcontext() [all …]
|
D | process_32.c | 31 void show_regs(struct pt_regs * regs) in show_regs() argument 36 pr_info("PC is at %pS\n", (void *)instruction_pointer(regs)); in show_regs() 37 pr_info("PR is at %pS\n", (void *)regs->pr); in show_regs() 39 pr_info("PC : %08lx SP : %08lx SR : %08lx ", regs->pc, in show_regs() 40 regs->regs[15], regs->sr); in show_regs() 48 regs->regs[0], regs->regs[1], regs->regs[2], regs->regs[3]); in show_regs() 50 regs->regs[4], regs->regs[5], regs->regs[6], regs->regs[7]); in show_regs() 52 regs->regs[8], regs->regs[9], regs->regs[10], regs->regs[11]); in show_regs() 54 regs->regs[12], regs->regs[13], regs->regs[14]); in show_regs() 56 regs->mach, regs->macl, regs->gbr, regs->pr); in show_regs() [all …]
|
/linux-5.19.10/arch/arc/kernel/ |
D | signal.c | 64 static int save_arcv2_regs(struct sigcontext *mctx, struct pt_regs *regs) in save_arcv2_regs() argument 70 v2abi.r30 = regs->r30; in save_arcv2_regs() 72 v2abi.r58 = regs->r58; in save_arcv2_regs() 73 v2abi.r59 = regs->r59; in save_arcv2_regs() 82 static int restore_arcv2_regs(struct sigcontext *mctx, struct pt_regs *regs) in restore_arcv2_regs() argument 90 regs->r30 = v2abi.r30; in restore_arcv2_regs() 92 regs->r58 = v2abi.r58; in restore_arcv2_regs() 93 regs->r59 = v2abi.r59; in restore_arcv2_regs() 100 stash_usr_regs(struct rt_sigframe __user *sf, struct pt_regs *regs, in stash_usr_regs() argument 106 uregs.scratch.bta = regs->bta; in stash_usr_regs() [all …]
|
D | troubleshoot.c | 21 static noinline void print_regs_scratch(struct pt_regs *regs) in print_regs_scratch() argument 24 regs->bta, regs->sp, regs->fp, (void *)regs->blink); in print_regs_scratch() 26 regs->lp_start, regs->lp_end, regs->lp_count); in print_regs_scratch() 33 regs->r0, regs->r1, regs->r2, in print_regs_scratch() 34 regs->r3, regs->r4, regs->r5, in print_regs_scratch() 35 regs->r6, regs->r7, regs->r8, in print_regs_scratch() 36 regs->r9, regs->r10, regs->r11, in print_regs_scratch() 37 regs->r12); in print_regs_scratch() 40 static void print_regs_callee(struct callee_regs *regs) in print_regs_callee() argument 47 regs->r13, regs->r14, in print_regs_callee() [all …]
|
/linux-5.19.10/tools/testing/selftests/x86/ |
D | ptrace_syscall.c | 201 struct user_regs_struct regs; in test_ptrace_syscall_restart() local 208 if (ptrace(PTRACE_GETREGS, chld, 0, ®s) != 0) in test_ptrace_syscall_restart() 211 if (regs.user_syscall_nr != SYS_gettid || in test_ptrace_syscall_restart() 212 regs.user_arg0 != 10 || regs.user_arg1 != 11 || in test_ptrace_syscall_restart() 213 regs.user_arg2 != 12 || regs.user_arg3 != 13 || in test_ptrace_syscall_restart() 214 regs.user_arg4 != 14 || regs.user_arg5 != 15) { in test_ptrace_syscall_restart() 215 …regs.user_syscall_nr, (unsigned long)regs.user_arg0, (unsigned long)regs.user_arg1, (unsigned long… in test_ptrace_syscall_restart() 222 (unsigned long)regs.user_ip); in test_ptrace_syscall_restart() 230 regs.user_ax = regs.user_syscall_nr; in test_ptrace_syscall_restart() 231 regs.user_ip -= 2; in test_ptrace_syscall_restart() [all …]
|
/linux-5.19.10/arch/x86/kernel/ |
D | traps.c | 78 static inline void cond_local_irq_enable(struct pt_regs *regs) in cond_local_irq_enable() argument 80 if (regs->flags & X86_EFLAGS_IF) in cond_local_irq_enable() 84 static inline void cond_local_irq_disable(struct pt_regs *regs) in cond_local_irq_disable() argument 86 if (regs->flags & X86_EFLAGS_IF) in cond_local_irq_disable() 104 struct pt_regs *regs, long error_code) in do_trap_no_signal() argument 106 if (v8086_mode(regs)) { in do_trap_no_signal() 112 if (!handle_vm86_trap((struct kernel_vm86_regs *) regs, in do_trap_no_signal() 116 } else if (!user_mode(regs)) { in do_trap_no_signal() 117 if (fixup_exception(regs, trapnr, error_code, 0)) in do_trap_no_signal() 122 die(str, regs, error_code); in do_trap_no_signal() [all …]
|
/linux-5.19.10/tools/testing/selftests/powerpc/ptrace/ |
D | ptrace-syscall.c | 56 struct pt_regs regs; in test_ptrace_syscall_restart() local 96 if (ptrace(PTRACE_GETREGS, chld, 0, ®s) != 0) in test_ptrace_syscall_restart() 103 if (regs.user_syscall_nr != SYS_gettid || in test_ptrace_syscall_restart() 104 regs.user_arg0 != 10 || regs.user_arg1 != 11 || in test_ptrace_syscall_restart() 105 regs.user_arg2 != 12 || regs.user_arg3 != 13 || in test_ptrace_syscall_restart() 106 regs.user_arg4 != 14 || regs.user_arg5 != 15) { in test_ptrace_syscall_restart() 108 (unsigned long)regs.user_syscall_nr, in test_ptrace_syscall_restart() 109 (unsigned long)regs.user_arg0, in test_ptrace_syscall_restart() 110 (unsigned long)regs.user_arg1, in test_ptrace_syscall_restart() 111 (unsigned long)regs.user_arg2, in test_ptrace_syscall_restart() [all …]
|
/linux-5.19.10/arch/x86/um/asm/ |
D | elf.h | 36 #define ELF_PLAT_INIT(regs, load_addr) do { \ argument 37 PT_REGS_BX(regs) = 0; \ 38 PT_REGS_CX(regs) = 0; \ 39 PT_REGS_DX(regs) = 0; \ 40 PT_REGS_SI(regs) = 0; \ 41 PT_REGS_DI(regs) = 0; \ 42 PT_REGS_BP(regs) = 0; \ 43 PT_REGS_AX(regs) = 0; \ 48 #define ELF_CORE_COPY_REGS(pr_reg, regs) do { \ argument 49 pr_reg[0] = PT_REGS_BX(regs); \ [all …]
|
/linux-5.19.10/arch/x86/entry/ |
D | common.c | 40 static __always_inline bool do_syscall_x64(struct pt_regs *regs, int nr) in do_syscall_x64() argument 50 regs->ax = sys_call_table[unr](regs); in do_syscall_x64() 56 static __always_inline bool do_syscall_x32(struct pt_regs *regs, int nr) in do_syscall_x32() argument 67 regs->ax = x32_sys_call_table[xnr](regs); in do_syscall_x32() 73 __visible noinstr void do_syscall_64(struct pt_regs *regs, int nr) in do_syscall_64() argument 76 nr = syscall_enter_from_user_mode(regs, nr); in do_syscall_64() 80 if (!do_syscall_x64(regs, nr) && !do_syscall_x32(regs, nr) && nr != -1) { in do_syscall_64() 82 regs->ax = __x64_sys_ni_syscall(regs); in do_syscall_64() 86 syscall_exit_to_user_mode(regs); in do_syscall_64() 91 static __always_inline int syscall_32_enter(struct pt_regs *regs) in syscall_32_enter() argument [all …]
|