Lines Matching refs:error_code

123 is_prefetch(struct pt_regs *regs, unsigned long error_code, unsigned long addr)  in is_prefetch()  argument
133 if (error_code & X86_PF_INSTR) in is_prefetch()
644 show_fault_oops(struct pt_regs *regs, unsigned long error_code, in show_fault_oops() argument
650 if (error_code & X86_PF_INSTR) { in show_fault_oops()
678 pgtable_bad(struct pt_regs *regs, unsigned long error_code, in pgtable_bad() argument
695 tsk->thread.error_code = error_code; in pgtable_bad()
697 if (__die("Bad pagetable", regs, error_code)) in pgtable_bad()
704 no_context(struct pt_regs *regs, unsigned long error_code, in no_context() argument
729 tsk->thread.error_code = error_code | X86_PF_USER; in no_context()
785 if (is_prefetch(regs, error_code, address)) in no_context()
797 show_fault_oops(regs, error_code, address); in no_context()
804 tsk->thread.error_code = error_code; in no_context()
807 if (__die("Oops", regs, error_code)) in no_context()
821 show_signal_msg(struct pt_regs *regs, unsigned long error_code, in show_signal_msg() argument
834 (void *)regs->ip, (void *)regs->sp, error_code); in show_signal_msg()
844 __bad_area_nosemaphore(struct pt_regs *regs, unsigned long error_code, in __bad_area_nosemaphore() argument
850 if (error_code & X86_PF_USER) { in __bad_area_nosemaphore()
860 if (is_prefetch(regs, error_code, address)) in __bad_area_nosemaphore()
871 if (unlikely((error_code & X86_PF_INSTR) && in __bad_area_nosemaphore()
884 error_code |= X86_PF_PROT; in __bad_area_nosemaphore()
887 show_signal_msg(regs, error_code, address, tsk); in __bad_area_nosemaphore()
890 tsk->thread.error_code = error_code; in __bad_area_nosemaphore()
901 no_context(regs, error_code, address, SIGSEGV, si_code); in __bad_area_nosemaphore()
905 bad_area_nosemaphore(struct pt_regs *regs, unsigned long error_code, in bad_area_nosemaphore() argument
908 __bad_area_nosemaphore(regs, error_code, address, pkey, SEGV_MAPERR); in bad_area_nosemaphore()
912 __bad_area(struct pt_regs *regs, unsigned long error_code, in __bad_area() argument
927 __bad_area_nosemaphore(regs, error_code, address, in __bad_area()
932 bad_area(struct pt_regs *regs, unsigned long error_code, unsigned long address) in bad_area() argument
934 __bad_area(regs, error_code, address, NULL, SEGV_MAPERR); in bad_area()
937 static inline bool bad_area_access_from_pkeys(unsigned long error_code, in bad_area_access_from_pkeys() argument
945 if (error_code & X86_PF_PK) in bad_area_access_from_pkeys()
948 if (!arch_vma_access_permitted(vma, (error_code & X86_PF_WRITE), in bad_area_access_from_pkeys()
949 (error_code & X86_PF_INSTR), foreign)) in bad_area_access_from_pkeys()
955 bad_area_access_error(struct pt_regs *regs, unsigned long error_code, in bad_area_access_error() argument
963 if (bad_area_access_from_pkeys(error_code, vma)) in bad_area_access_error()
964 __bad_area(regs, error_code, address, vma, SEGV_PKUERR); in bad_area_access_error()
966 __bad_area(regs, error_code, address, vma, SEGV_ACCERR); in bad_area_access_error()
970 do_sigbus(struct pt_regs *regs, unsigned long error_code, unsigned long address, in do_sigbus() argument
977 if (!(error_code & X86_PF_USER)) { in do_sigbus()
978 no_context(regs, error_code, address, SIGBUS, BUS_ADRERR); in do_sigbus()
983 if (is_prefetch(regs, error_code, address)) in do_sigbus()
987 tsk->thread.error_code = error_code; in do_sigbus()
1002 mm_fault_error(struct pt_regs *regs, unsigned long error_code, in mm_fault_error() argument
1005 if (fatal_signal_pending(current) && !(error_code & X86_PF_USER)) { in mm_fault_error()
1006 no_context(regs, error_code, address, 0, 0); in mm_fault_error()
1012 if (!(error_code & X86_PF_USER)) { in mm_fault_error()
1013 no_context(regs, error_code, address, in mm_fault_error()
1027 do_sigbus(regs, error_code, address, pkey, fault); in mm_fault_error()
1029 bad_area_nosemaphore(regs, error_code, address, pkey); in mm_fault_error()
1035 static int spurious_fault_check(unsigned long error_code, pte_t *pte) in spurious_fault_check() argument
1037 if ((error_code & X86_PF_WRITE) && !pte_write(*pte)) in spurious_fault_check()
1040 if ((error_code & X86_PF_INSTR) && !pte_exec(*pte)) in spurious_fault_check()
1046 if ((error_code & X86_PF_PK)) in spurious_fault_check()
1074 spurious_fault(unsigned long error_code, unsigned long address) in spurious_fault() argument
1092 if (error_code != (X86_PF_WRITE | X86_PF_PROT) && in spurious_fault()
1093 error_code != (X86_PF_INSTR | X86_PF_PROT)) in spurious_fault()
1105 return spurious_fault_check(error_code, (pte_t *) p4d); in spurious_fault()
1112 return spurious_fault_check(error_code, (pte_t *) pud); in spurious_fault()
1119 return spurious_fault_check(error_code, (pte_t *) pmd); in spurious_fault()
1125 ret = spurious_fault_check(error_code, pte); in spurious_fault()
1133 ret = spurious_fault_check(error_code, (pte_t *) pmd); in spurious_fault()
1143 access_error(unsigned long error_code, struct vm_area_struct *vma) in access_error() argument
1153 if (error_code & X86_PF_PK) in access_error()
1161 if (!arch_vma_access_permitted(vma, (error_code & X86_PF_WRITE), in access_error()
1162 (error_code & X86_PF_INSTR), foreign)) in access_error()
1165 if (error_code & X86_PF_WRITE) { in access_error()
1173 if (unlikely(error_code & X86_PF_PROT)) in access_error()
1188 static inline bool smap_violation(int error_code, struct pt_regs *regs) in smap_violation() argument
1196 if (error_code & X86_PF_USER) in smap_violation()
1211 __do_page_fault(struct pt_regs *regs, unsigned long error_code, in __do_page_fault() argument
1243 if (!(error_code & (X86_PF_RSVD | X86_PF_USER | X86_PF_PROT))) { in __do_page_fault()
1249 if (spurious_fault(error_code, address)) in __do_page_fault()
1259 bad_area_nosemaphore(regs, error_code, address, NULL); in __do_page_fault()
1268 if (unlikely(error_code & X86_PF_RSVD)) in __do_page_fault()
1269 pgtable_bad(regs, error_code, address); in __do_page_fault()
1271 if (unlikely(smap_violation(error_code, regs))) { in __do_page_fault()
1272 bad_area_nosemaphore(regs, error_code, address, NULL); in __do_page_fault()
1281 bad_area_nosemaphore(regs, error_code, address, NULL); in __do_page_fault()
1294 error_code |= X86_PF_USER; in __do_page_fault()
1303 if (error_code & X86_PF_WRITE) in __do_page_fault()
1305 if (error_code & X86_PF_INSTR) in __do_page_fault()
1325 if (!(error_code & X86_PF_USER) && in __do_page_fault()
1327 bad_area_nosemaphore(regs, error_code, address, NULL); in __do_page_fault()
1343 bad_area(regs, error_code, address); in __do_page_fault()
1349 bad_area(regs, error_code, address); in __do_page_fault()
1352 if (error_code & X86_PF_USER) { in __do_page_fault()
1360 bad_area(regs, error_code, address); in __do_page_fault()
1365 bad_area(regs, error_code, address); in __do_page_fault()
1374 if (unlikely(access_error(error_code, vma))) { in __do_page_fault()
1375 bad_area_access_error(regs, error_code, address, vma); in __do_page_fault()
1417 no_context(regs, error_code, address, SIGBUS, BUS_ADRERR); in __do_page_fault()
1423 mm_fault_error(regs, error_code, address, &pkey, fault); in __do_page_fault()
1445 unsigned long error_code) in trace_page_fault_entries() argument
1448 trace_page_fault_user(address, regs, error_code); in trace_page_fault_entries()
1450 trace_page_fault_kernel(address, regs, error_code); in trace_page_fault_entries()
1461 do_page_fault(struct pt_regs *regs, unsigned long error_code) in do_page_fault() argument
1468 trace_page_fault_entries(address, regs, error_code); in do_page_fault()
1470 __do_page_fault(regs, error_code, address); in do_page_fault()