Lines Matching refs:esr
76 #define ESR_ELx_EC(esr) (((esr) & ESR_ELx_EC_MASK) >> ESR_ELx_EC_SHIFT)
81 #define ESR_ELx_ISS(esr) ((esr) & ESR_ELx_ISS_MASK)
84 #define ESR_ELx_ISS2(esr) (((esr) & ESR_ELx_ISS2_MASK) >> ESR_ELx_ISS2_SHIFT)
243 #define ESR_ELx_SYS64_ISS_RT(esr) \
244 (((esr) & ESR_ELx_SYS64_ISS_RT_MASK) >> ESR_ELx_SYS64_ISS_RT_SHIFT)
392 #define ESR_ELx_SME_ISS_SMTC(esr) ((esr) & ESR_ELx_SME_ISS_SMTC_MASK)
405 #define ESR_ELx_MOPS_ISS_DESTREG(esr) (((esr) & (UL(0x1f) << 10)) >> 10)
406 #define ESR_ELx_MOPS_ISS_SRCREG(esr) (((esr) & (UL(0x1f) << 5)) >> 5)
407 #define ESR_ELx_MOPS_ISS_SIZEREG(esr) (((esr) & (UL(0x1f) << 0)) >> 0)
437 static inline unsigned long esr_brk_comment(unsigned long esr)
439 return esr & ESR_ELx_BRK64_ISS_COMMENT_MASK;
442 static inline bool esr_is_data_abort(unsigned long esr)
444 const unsigned long ec = ESR_ELx_EC(esr);
449 static inline bool esr_is_cfi_brk(unsigned long esr)
451 return ESR_ELx_EC(esr) == ESR_ELx_EC_BRK64 &&
452 (esr_brk_comment(esr) & ~CFI_BRK_IMM_MASK) == CFI_BRK_IMM_BASE;
455 static inline bool esr_is_ubsan_brk(unsigned long esr)
457 return (esr_brk_comment(esr) & ~UBSAN_BRK_MASK) == UBSAN_BRK_IMM;
460 static inline bool esr_fsc_is_translation_fault(unsigned long esr)
462 esr = esr & ESR_ELx_FSC;
464 return (esr == ESR_ELx_FSC_FAULT_L(3)) ||
465 (esr == ESR_ELx_FSC_FAULT_L(2)) ||
466 (esr == ESR_ELx_FSC_FAULT_L(1)) ||
467 (esr == ESR_ELx_FSC_FAULT_L(0)) ||
468 (esr == ESR_ELx_FSC_FAULT_L(-1));
471 static inline bool esr_fsc_is_permission_fault(unsigned long esr)
473 esr = esr & ESR_ELx_FSC;
475 return (esr == ESR_ELx_FSC_PERM_L(3)) ||
476 (esr == ESR_ELx_FSC_PERM_L(2)) ||
477 (esr == ESR_ELx_FSC_PERM_L(1)) ||
478 (esr == ESR_ELx_FSC_PERM_L(0));
481 static inline bool esr_fsc_is_access_flag_fault(unsigned long esr)
483 esr = esr & ESR_ELx_FSC;
485 return (esr == ESR_ELx_FSC_ACCESS_L(3)) ||
486 (esr == ESR_ELx_FSC_ACCESS_L(2)) ||
487 (esr == ESR_ELx_FSC_ACCESS_L(1)) ||
488 (esr == ESR_ELx_FSC_ACCESS_L(0));
491 static inline bool esr_fsc_is_addr_sz_fault(unsigned long esr)
493 esr &= ESR_ELx_FSC;
495 return (esr == ESR_ELx_FSC_ADDRSZ_L(3)) ||
496 (esr == ESR_ELx_FSC_ADDRSZ_L(2)) ||
497 (esr == ESR_ELx_FSC_ADDRSZ_L(1)) ||
498 (esr == ESR_ELx_FSC_ADDRSZ_L(0)) ||
499 (esr == ESR_ELx_FSC_ADDRSZ_L(-1));
502 static inline bool esr_fsc_is_sea_ttw(unsigned long esr)
504 esr = esr & ESR_ELx_FSC;
506 return (esr == ESR_ELx_FSC_SEA_TTW(3)) ||
507 (esr == ESR_ELx_FSC_SEA_TTW(2)) ||
508 (esr == ESR_ELx_FSC_SEA_TTW(1)) ||
509 (esr == ESR_ELx_FSC_SEA_TTW(0)) ||
510 (esr == ESR_ELx_FSC_SEA_TTW(-1));
513 static inline bool esr_fsc_is_secc_ttw(unsigned long esr)
515 esr = esr & ESR_ELx_FSC;
517 return (esr == ESR_ELx_FSC_SECC_TTW(3)) ||
518 (esr == ESR_ELx_FSC_SECC_TTW(2)) ||
519 (esr == ESR_ELx_FSC_SECC_TTW(1)) ||
520 (esr == ESR_ELx_FSC_SECC_TTW(0)) ||
521 (esr == ESR_ELx_FSC_SECC_TTW(-1));
525 static inline bool esr_iss_is_eretax(unsigned long esr)
527 return esr & ESR_ELx_ERET_ISS_ERET;
531 static inline bool esr_iss_is_eretab(unsigned long esr)
533 return esr & ESR_ELx_ERET_ISS_ERETA;
536 const char *esr_get_class_string(unsigned long esr);