Lines Matching refs:esr

246 	unsigned int esr = tsk->thread.fault_code;  in arm64_show_signal()  local
256 if (esr) in arm64_show_signal()
257 pr_cont("%s, ESR 0x%08x, ", esr_get_class_string(esr), esr); in arm64_show_signal()
510 void do_ptrauth_fault(struct pt_regs *regs, unsigned int esr) in do_ptrauth_fault() argument
517 force_signal_inject(SIGILL, ILL_ILLOPN, regs->pc, esr); in do_ptrauth_fault()
541 static void user_cache_maint_handler(unsigned int esr, struct pt_regs *regs) in user_cache_maint_handler() argument
544 int rt = ESR_ELx_SYS64_ISS_RT(esr); in user_cache_maint_handler()
545 int crm = (esr & ESR_ELx_SYS64_ISS_CRM_MASK) >> ESR_ELx_SYS64_ISS_CRM_SHIFT; in user_cache_maint_handler()
581 static void ctr_read_handler(unsigned int esr, struct pt_regs *regs) in ctr_read_handler() argument
583 int rt = ESR_ELx_SYS64_ISS_RT(esr); in ctr_read_handler()
600 static void cntvct_read_handler(unsigned int esr, struct pt_regs *regs) in cntvct_read_handler() argument
602 int rt = ESR_ELx_SYS64_ISS_RT(esr); in cntvct_read_handler()
608 static void cntfrq_read_handler(unsigned int esr, struct pt_regs *regs) in cntfrq_read_handler() argument
610 int rt = ESR_ELx_SYS64_ISS_RT(esr); in cntfrq_read_handler()
616 static void mrs_handler(unsigned int esr, struct pt_regs *regs) in mrs_handler() argument
620 rt = ESR_ELx_SYS64_ISS_RT(esr); in mrs_handler()
621 sysreg = esr_sys64_to_sysreg(esr); in mrs_handler()
627 static void wfi_handler(unsigned int esr, struct pt_regs *regs) in wfi_handler() argument
635 void (*handler)(unsigned int esr, struct pt_regs *regs);
678 static bool cp15_cond_valid(unsigned int esr, struct pt_regs *regs) in cp15_cond_valid() argument
683 if (!(esr & ESR_ELx_CV)) { in cp15_cond_valid()
692 cond = (esr & ESR_ELx_COND_MASK) >> ESR_ELx_COND_SHIFT; in cp15_cond_valid()
698 static void compat_cntfrq_read_handler(unsigned int esr, struct pt_regs *regs) in compat_cntfrq_read_handler() argument
700 int reg = (esr & ESR_ELx_CP15_32_ISS_RT_MASK) >> ESR_ELx_CP15_32_ISS_RT_SHIFT; in compat_cntfrq_read_handler()
715 static void compat_cntvct_read_handler(unsigned int esr, struct pt_regs *regs) in compat_cntvct_read_handler() argument
717 int rt = (esr & ESR_ELx_CP15_64_ISS_RT_MASK) >> ESR_ELx_CP15_64_ISS_RT_SHIFT; in compat_cntvct_read_handler()
718 int rt2 = (esr & ESR_ELx_CP15_64_ISS_RT2_MASK) >> ESR_ELx_CP15_64_ISS_RT2_SHIFT; in compat_cntvct_read_handler()
735 void do_cp15instr(unsigned int esr, struct pt_regs *regs) in do_cp15instr() argument
739 if (!cp15_cond_valid(esr, regs)) { in do_cp15instr()
748 switch (ESR_ELx_EC(esr)) { in do_cp15instr()
761 if ((hook->esr_mask & esr) == hook->esr_val) { in do_cp15instr()
762 hook->handler(esr, regs); in do_cp15instr()
776 void do_sysinstr(unsigned int esr, struct pt_regs *regs) in do_sysinstr() argument
781 if ((hook->esr_mask & esr) == hook->esr_val) { in do_sysinstr()
782 hook->handler(esr, regs); in do_sysinstr()
840 const char *esr_get_class_string(u32 esr) in esr_get_class_string() argument
842 return esr_class_str[ESR_ELx_EC(esr)]; in esr_get_class_string()
849 void bad_el0_sync(struct pt_regs *regs, int reason, unsigned int esr) in bad_el0_sync() argument
854 current->thread.fault_code = esr; in bad_el0_sync()
865 void panic_bad_stack(struct pt_regs *regs, unsigned int esr, unsigned long far) in panic_bad_stack() argument
874 pr_emerg("ESR: 0x%08x -- %s\n", esr, esr_get_class_string(esr)); in panic_bad_stack()
895 void __noreturn arm64_serror_panic(struct pt_regs *regs, u32 esr) in arm64_serror_panic() argument
900 smp_processor_id(), esr, esr_get_class_string(esr)); in arm64_serror_panic()
910 bool arm64_is_fatal_ras_serror(struct pt_regs *regs, unsigned int esr) in arm64_is_fatal_ras_serror() argument
912 u32 aet = arm64_ras_serror_get_severity(esr); in arm64_is_fatal_ras_serror()
938 arm64_serror_panic(regs, esr); in arm64_is_fatal_ras_serror()
942 void do_serror(struct pt_regs *regs, unsigned int esr) in do_serror() argument
945 if (!arm64_is_ras_serror(esr) || arm64_is_fatal_ras_serror(regs, esr)) in do_serror()
946 arm64_serror_panic(regs, esr); in do_serror()
963 static int bug_handler(struct pt_regs *regs, unsigned int esr) in bug_handler() argument
988 static int reserved_fault_handler(struct pt_regs *regs, unsigned int esr) in reserved_fault_handler() argument
1008 #define KASAN_ESR_SIZE(esr) (1 << ((esr) & KASAN_ESR_SIZE_MASK)) argument
1010 static int kasan_handler(struct pt_regs *regs, unsigned int esr) in kasan_handler() argument
1012 bool recover = esr & KASAN_ESR_RECOVER; in kasan_handler()
1013 bool write = esr & KASAN_ESR_WRITE; in kasan_handler()
1014 size_t size = KASAN_ESR_SIZE(esr); in kasan_handler()
1053 int __init early_brk64(unsigned long addr, unsigned int esr, in early_brk64() argument
1057 unsigned int comment = esr & ESR_ELx_BRK64_ISS_COMMENT_MASK; in early_brk64()
1060 return kasan_handler(regs, esr) != DBG_HOOK_HANDLED; in early_brk64()
1062 return bug_handler(regs, esr) != DBG_HOOK_HANDLED; in early_brk64()