Lines Matching refs:esr
155 unsigned int esr = tsk->thread.fault_code; in arm64_show_signal() local
165 if (esr) in arm64_show_signal()
166 pr_cont("%s, ESR 0x%08x, ", esr_get_class_string(esr), esr); in arm64_show_signal()
419 void do_ptrauth_fault(struct pt_regs *regs, unsigned int esr) in do_ptrauth_fault() argument
426 force_signal_inject(SIGILL, ILL_ILLOPN, regs->pc, esr); in do_ptrauth_fault()
450 static void user_cache_maint_handler(unsigned int esr, struct pt_regs *regs) in user_cache_maint_handler() argument
453 int rt = ESR_ELx_SYS64_ISS_RT(esr); in user_cache_maint_handler()
454 int crm = (esr & ESR_ELx_SYS64_ISS_CRM_MASK) >> ESR_ELx_SYS64_ISS_CRM_SHIFT; in user_cache_maint_handler()
489 static void ctr_read_handler(unsigned int esr, struct pt_regs *regs) in ctr_read_handler() argument
491 int rt = ESR_ELx_SYS64_ISS_RT(esr); in ctr_read_handler()
508 static void cntvct_read_handler(unsigned int esr, struct pt_regs *regs) in cntvct_read_handler() argument
510 int rt = ESR_ELx_SYS64_ISS_RT(esr); in cntvct_read_handler()
516 static void cntfrq_read_handler(unsigned int esr, struct pt_regs *regs) in cntfrq_read_handler() argument
518 int rt = ESR_ELx_SYS64_ISS_RT(esr); in cntfrq_read_handler()
524 static void mrs_handler(unsigned int esr, struct pt_regs *regs) in mrs_handler() argument
528 rt = ESR_ELx_SYS64_ISS_RT(esr); in mrs_handler()
529 sysreg = esr_sys64_to_sysreg(esr); in mrs_handler()
535 static void wfi_handler(unsigned int esr, struct pt_regs *regs) in wfi_handler() argument
543 void (*handler)(unsigned int esr, struct pt_regs *regs);
586 static bool cp15_cond_valid(unsigned int esr, struct pt_regs *regs) in cp15_cond_valid() argument
591 if (!(esr & ESR_ELx_CV)) { in cp15_cond_valid()
600 cond = (esr & ESR_ELx_COND_MASK) >> ESR_ELx_COND_SHIFT; in cp15_cond_valid()
606 static void compat_cntfrq_read_handler(unsigned int esr, struct pt_regs *regs) in compat_cntfrq_read_handler() argument
608 int reg = (esr & ESR_ELx_CP15_32_ISS_RT_MASK) >> ESR_ELx_CP15_32_ISS_RT_SHIFT; in compat_cntfrq_read_handler()
623 static void compat_cntvct_read_handler(unsigned int esr, struct pt_regs *regs) in compat_cntvct_read_handler() argument
625 int rt = (esr & ESR_ELx_CP15_64_ISS_RT_MASK) >> ESR_ELx_CP15_64_ISS_RT_SHIFT; in compat_cntvct_read_handler()
626 int rt2 = (esr & ESR_ELx_CP15_64_ISS_RT2_MASK) >> ESR_ELx_CP15_64_ISS_RT2_SHIFT; in compat_cntvct_read_handler()
643 void do_cp15instr(unsigned int esr, struct pt_regs *regs) in do_cp15instr() argument
647 if (!cp15_cond_valid(esr, regs)) { in do_cp15instr()
656 switch (ESR_ELx_EC(esr)) { in do_cp15instr()
669 if ((hook->esr_mask & esr) == hook->esr_val) { in do_cp15instr()
670 hook->handler(esr, regs); in do_cp15instr()
684 void do_sysinstr(unsigned int esr, struct pt_regs *regs) in do_sysinstr() argument
689 if ((hook->esr_mask & esr) == hook->esr_val) { in do_sysinstr()
690 hook->handler(esr, regs); in do_sysinstr()
748 const char *esr_get_class_string(u32 esr) in esr_get_class_string() argument
750 return esr_class_str[ESR_ELx_EC(esr)]; in esr_get_class_string()
757 asmlinkage void notrace bad_mode(struct pt_regs *regs, int reason, unsigned int esr) in bad_mode() argument
764 handler[reason], smp_processor_id(), esr, in bad_mode()
765 esr_get_class_string(esr)); in bad_mode()
776 void bad_el0_sync(struct pt_regs *regs, int reason, unsigned int esr) in bad_el0_sync() argument
781 current->thread.fault_code = esr; in bad_el0_sync()
797 unsigned int esr = read_sysreg(esr_el1); in handle_bad_stack() local
805 pr_emerg("ESR: 0x%08x -- %s\n", esr, esr_get_class_string(esr)); in handle_bad_stack()
826 void __noreturn arm64_serror_panic(struct pt_regs *regs, u32 esr) in arm64_serror_panic() argument
831 smp_processor_id(), esr, esr_get_class_string(esr)); in arm64_serror_panic()
841 bool arm64_is_fatal_ras_serror(struct pt_regs *regs, unsigned int esr) in arm64_is_fatal_ras_serror() argument
843 u32 aet = arm64_ras_serror_get_severity(esr); in arm64_is_fatal_ras_serror()
869 arm64_serror_panic(regs, esr); in arm64_is_fatal_ras_serror()
873 asmlinkage void noinstr do_serror(struct pt_regs *regs, unsigned int esr) in do_serror() argument
878 if (!arm64_is_ras_serror(esr) || arm64_is_fatal_ras_serror(regs, esr)) in do_serror()
879 arm64_serror_panic(regs, esr); in do_serror()
898 static int bug_handler(struct pt_regs *regs, unsigned int esr) in bug_handler() argument
923 static int reserved_fault_handler(struct pt_regs *regs, unsigned int esr) in reserved_fault_handler() argument
943 #define KASAN_ESR_SIZE(esr) (1 << ((esr) & KASAN_ESR_SIZE_MASK)) argument
945 static int kasan_handler(struct pt_regs *regs, unsigned int esr) in kasan_handler() argument
947 bool recover = esr & KASAN_ESR_RECOVER; in kasan_handler()
948 bool write = esr & KASAN_ESR_WRITE; in kasan_handler()
949 size_t size = KASAN_ESR_SIZE(esr); in kasan_handler()
988 int __init early_brk64(unsigned long addr, unsigned int esr, in early_brk64() argument
992 unsigned int comment = esr & ESR_ELx_BRK64_ISS_COMMENT_MASK; in early_brk64()
995 return kasan_handler(regs, esr) != DBG_HOOK_HANDLED; in early_brk64()
997 return bug_handler(regs, esr) != DBG_HOOK_HANDLED; in early_brk64()