Lines Matching +full:no +full:- +full:pc +full:- +full:write
46 [VEC_RESETPC] = "RESET PC",
136 unsigned long fslw = fp->un.fmt4.pc; /* is really FSLW for access error */ in access_error060()
138 pr_debug("fslw=%#lx, fa=%#lx\n", fslw, fp->un.fmt4.effaddr); in access_error060()
141 /* branch prediction error -> clear branch cache */ in access_error060()
146 /* return if there's no other error */ in access_error060()
153 unsigned long addr = fp->un.fmt4.effaddr; in access_error060()
156 addr = (addr + PAGE_SIZE - 1) & PAGE_MASK; in access_error060()
166 do_page_fault(&fp->ptregs, addr, errorcode); in access_error060()
171 send_fault_sig(&fp->ptregs); in access_error060()
173 send_fault_sig(&fp->ptregs) > 0) { in access_error060()
174 pr_err("pc=%#lx, fa=%#lx\n", fp->ptregs.pc, in access_error060()
175 fp->un.fmt4.effaddr); in access_error060()
233 fp->un.fmt7.faddr = wba; in fix_xframe040()
234 fp->un.fmt7.ssw = wbs & 0xff; in fix_xframe040()
235 if (wba != current->thread.faddr) in fix_xframe040()
236 fp->un.fmt7.ssw |= MA_040; in fix_xframe040()
243 if (fp->un.fmt7.wb1s & WBV_040) in do_040writebacks()
247 if ((fp->un.fmt7.wb2s & WBV_040) && in do_040writebacks()
248 !(fp->un.fmt7.wb2s & WBTT_040)) { in do_040writebacks()
249 res = do_040writeback1(fp->un.fmt7.wb2s, fp->un.fmt7.wb2a, in do_040writebacks()
250 fp->un.fmt7.wb2d); in do_040writebacks()
252 fix_xframe040(fp, fp->un.fmt7.wb2a, fp->un.fmt7.wb2s); in do_040writebacks()
254 fp->un.fmt7.wb2s = 0; in do_040writebacks()
258 if (fp->un.fmt7.wb3s & WBV_040 && (!res || fp->un.fmt7.wb3s & 4)) { in do_040writebacks()
259 res = do_040writeback1(fp->un.fmt7.wb3s, fp->un.fmt7.wb3a, in do_040writebacks()
260 fp->un.fmt7.wb3d); in do_040writebacks()
263 fix_xframe040(fp, fp->un.fmt7.wb3a, fp->un.fmt7.wb3s); in do_040writebacks()
265 fp->un.fmt7.wb2s = fp->un.fmt7.wb3s; in do_040writebacks()
266 fp->un.fmt7.wb3s &= (~WBV_040); in do_040writebacks()
267 fp->un.fmt7.wb2a = fp->un.fmt7.wb3a; in do_040writebacks()
268 fp->un.fmt7.wb2d = fp->un.fmt7.wb3d; in do_040writebacks()
271 fp->un.fmt7.wb3s = 0; in do_040writebacks()
275 send_fault_sig(&fp->ptregs); in do_040writebacks()
286 fp->un.fmt7.wb2s &= ~4; in berr_040cleanup()
287 fp->un.fmt7.wb3s &= ~4; in berr_040cleanup()
294 unsigned short ssw = fp->un.fmt7.ssw; in access_error040()
297 pr_debug("ssw=%#x, fa=%#lx\n", ssw, fp->un.fmt7.faddr); in access_error040()
298 pr_debug("wb1s=%#x, wb2s=%#x, wb3s=%#x\n", fp->un.fmt7.wb1s, in access_error040()
299 fp->un.fmt7.wb2s, fp->un.fmt7.wb3s); in access_error040()
301 fp->un.fmt7.wb2a, fp->un.fmt7.wb3a, in access_error040()
302 fp->un.fmt7.wb2d, fp->un.fmt7.wb3d); in access_error040()
305 unsigned long addr = fp->un.fmt7.faddr; in access_error040()
313 addr = (addr + 7) & -8; in access_error040()
330 if (do_page_fault(&fp->ptregs, addr, errorcode)) { in access_error040()
332 if (user_mode(&fp->ptregs)){ in access_error040()
334 pr_debug(".. was usermode - return\n"); in access_error040()
343 if (fp->un.fmt7.wb2a == fp->un.fmt7.faddr) in access_error040()
344 fp->un.fmt7.wb2s &= ~WBV_040; in access_error040()
345 if (fp->un.fmt7.wb3a == fp->un.fmt7.faddr) in access_error040()
346 fp->un.fmt7.wb3s &= ~WBV_040; in access_error040()
353 current->thread.signo = SIGBUS; in access_error040()
354 current->thread.faddr = fp->un.fmt7.faddr; in access_error040()
355 if (send_fault_sig(&fp->ptregs) >= 0) in access_error040()
357 fp->un.fmt7.faddr); in access_error040()
376 unsigned short ssw = fp->un.fmtb.ssw; in bus_error030()
382 fp->ptregs.format == 0xa ? fp->ptregs.pc + 2 : fp->un.fmtb.baddr - 2 in bus_error030()
384 fp->ptregs.format == 0xa ? fp->ptregs.pc + 4 : fp->un.fmtb.baddr); in bus_error030()
386 pr_debug("Data %s fault at %#010lx in %s (pc=%#lx)\n", in bus_error030()
387 ssw & RW ? "read" : "write", in bus_error030()
388 fp->un.fmtb.daddr, in bus_error030()
389 space_names[ssw & DFC], fp->ptregs.pc); in bus_error030()
392 * Check if this page should be demand-mapped. This needs to go before in bus_error030()
393 * the testing for a bad kernel-space access (demand-mapping applies in bus_error030()
399 if (mmu_emu_handle_fault (fp->un.fmtb.daddr, ssw & RW, 0)) in bus_error030()
403 /* Check for kernel-space pagefault (BAD). */ in bus_error030()
404 if (fp->ptregs.sr & PS_S) { in bus_error030()
408 if (mmu_emu_handle_fault (fp->un.fmtb.daddr, ssw & RW, 1)) in bus_error030()
413 fp->ptregs.pc); in bus_error030()
416 if((fp->ptregs.pc >= (unsigned long)&_sun3_map_test_start) && in bus_error030()
417 (fp->ptregs.pc <= (unsigned long)&_sun3_map_test_end)) { in bus_error030()
418 send_fault_sig(&fp->ptregs); in bus_error030()
422 pr_err("Data %s fault at %#010lx in %s (pc=%#lx)\n", in bus_error030()
423 ssw & RW ? "read" : "write", in bus_error030()
424 fp->un.fmtb.daddr, in bus_error030()
425 space_names[ssw & DFC], fp->ptregs.pc); in bus_error030()
429 die_if_kernel("Oops", &fp->ptregs,0); in bus_error030()
443 addr = fp->un.fmtb.daddr; in bus_error030()
445 // errorcode bit 0: 0 -> no page 1 -> protection fault in bus_error030()
446 // errorcode bit 1: 0 -> read fault 1 -> write fault in bus_error030()
448 // (buserr_type & SUN3_BUSERR_PROTERR) -> protection fault in bus_error030()
449 // (buserr_type & SUN3_BUSERR_INVALID) -> invalid page fault in bus_error030()
458 pr_debug("invalid %s access at %#lx from pc %#lx\n", in bus_error030()
459 !(ssw & RW) ? "write" : "read", addr, in bus_error030()
460 fp->ptregs.pc); in bus_error030()
461 die_if_kernel ("Oops", &fp->ptregs, buserr_type); in bus_error030()
466 //todo: wtf is RM bit? --m in bus_error030()
471 do_page_fault (&fp->ptregs, addr, errorcode); in bus_error030()
480 if (fp->ptregs.format == 0xA) in bus_error030()
481 addr = fp->ptregs.pc + 4; in bus_error030()
483 addr = fp->un.fmtb.baddr; in bus_error030()
485 addr -= 2; in bus_error030()
489 do_page_fault (&fp->ptregs, addr, 0); in bus_error030()
502 unsigned short ssw = fp->un.fmtb.ssw; in bus_error030()
507 pr_debug("pid = %x ", current->pid); in bus_error030()
513 fp->ptregs.format == 0xa ? fp->ptregs.pc + 2 : fp->un.fmtb.baddr - 2 in bus_error030()
515 fp->ptregs.format == 0xa ? fp->ptregs.pc + 4 : fp->un.fmtb.baddr); in bus_error030()
517 pr_debug("Data %s fault at %#010lx in %s (pc=%#lx)\n", in bus_error030()
518 ssw & RW ? "read" : "write", in bus_error030()
519 fp->un.fmtb.daddr, in bus_error030()
520 space_names[ssw & DFC], fp->ptregs.pc); in bus_error030()
527 addr = fp->un.fmtb.daddr; in bus_error030()
549 /* We might have an exception table for this PC */ in bus_error030()
550 if (ssw & 4 && !search_exception_tables(fp->ptregs.pc)) { in bus_error030()
551 pr_err("Data %s fault at %#010lx in %s (pc=%#lx)\n", in bus_error030()
552 ssw & RW ? "read" : "write", in bus_error030()
553 fp->un.fmtb.daddr, in bus_error030()
554 space_names[ssw & DFC], fp->ptregs.pc); in bus_error030()
559 if (do_page_fault (&fp->ptregs, addr, errorcode) < 0) in bus_error030()
563 if (!(ssw & RM) && send_fault_sig(&fp->ptregs) > 0) in bus_error030()
567 pr_err("invalid %s access at %#lx from pc %#lx\n", in bus_error030()
568 !(ssw & RW) ? "write" : "read", addr, in bus_error030()
569 fp->ptregs.pc); in bus_error030()
570 die_if_kernel("Oops",&fp->ptregs,mmusr); in bus_error030()
578 pr_err("weird %s access at %#lx from pc %#lx (ssw is %#x)\n", in bus_error030()
579 !(ssw & RW) ? "write" : "read", addr, in bus_error030()
580 fp->ptregs.pc, ssw); in bus_error030()
596 pr_debug("Unknown SIGSEGV - 1\n"); in bus_error030()
597 die_if_kernel("Oops",&fp->ptregs,mmusr); in bus_error030()
604 asm volatile ("ploadw %1,%0@" : /* no outputs */ in bus_error030()
607 asm volatile ("ploadr %1,%0@" : /* no outputs */ in bus_error030()
616 if (fp->ptregs.sr & PS_S) { in bus_error030()
617 pr_err("Instruction fault at %#010lx\n", fp->ptregs.pc); in bus_error030()
620 die_if_kernel("Oops",&fp->ptregs,0); in bus_error030()
626 if (fp->ptregs.format == 10) in bus_error030()
627 addr = fp->ptregs.pc + 4; in bus_error030()
629 addr = fp->un.fmtb.baddr; in bus_error030()
631 addr -= 2; in bus_error030()
633 if ((ssw & DF) && ((addr ^ fp->un.fmtb.daddr) & PAGE_MASK) == 0) in bus_error030()
654 do_page_fault (&fp->ptregs, addr, 0); in bus_error030()
656 pr_err("invalid insn access at %#lx from pc %#lx\n", in bus_error030()
657 addr, fp->ptregs.pc); in bus_error030()
658 pr_debug("Unknown SIGSEGV - 2\n"); in bus_error030()
659 die_if_kernel("Oops",&fp->ptregs,mmusr); in bus_error030()
666 asm volatile ("ploadr #2,%0@" : /* no outputs */ in bus_error030()
710 * bit 0 == 0 means no page found, 1 means protection fault in access_errorcf()
711 * bit 1 == 0 means read, 1 means write in access_errorcf()
715 need_page_fault = cf_tlb_miss(&fp->ptregs, 0, 0, 0); in access_errorcf()
716 addr = fp->ptregs.pc; in access_errorcf()
719 need_page_fault = cf_tlb_miss(&fp->ptregs, 0, 0, 1); in access_errorcf()
720 addr = fp->ptregs.pc + sizeof(long); in access_errorcf()
723 need_page_fault = cf_tlb_miss(&fp->ptregs, 1, 1, 0); in access_errorcf()
726 need_page_fault = cf_tlb_miss(&fp->ptregs, 0, 1, 0); in access_errorcf()
736 /* 1001 Write error*/ in access_errorcf()
747 if ((fs == 13) && (mmusr & MMUSR_WF)) /* rd-mod-wr access */ in access_errorcf()
748 err_code |= 2; /* bit1 - write, bit0 - protection */ in access_errorcf()
749 do_page_fault(&fp->ptregs, addr, err_code); in access_errorcf()
757 if (user_mode(&fp->ptregs)) in buserr_c()
758 current->thread.esp0 = (unsigned long) fp; in buserr_c()
760 pr_debug("*** Bus Error *** Format is %x\n", fp->ptregs.format); in buserr_c()
765 fs = (fp->ptregs.vector & 0x3) | in buserr_c()
766 ((fp->ptregs.vector & 0xc00) >> 8); in buserr_c()
784 switch (fp->ptregs.format) { in buserr_c()
802 die_if_kernel("bad frame format",&fp->ptregs,0); in buserr_c()
803 pr_debug("Unknown SIGSEGV - 4\n"); in buserr_c()
818 addr = (unsigned long)stack + THREAD_SIZE - 1; in show_trace()
819 endstack = (unsigned long *)(addr & -THREAD_SIZE); in show_trace()
851 pr_info("PC: [<%08lx>] %pS\n", regs->pc, (void *)regs->pc); in show_registers()
852 pr_info("SR: %04x SP: %p a2: %08lx\n", regs->sr, regs, regs->a2); in show_registers()
854 regs->d0, regs->d1, regs->d2, regs->d3); in show_registers()
856 regs->d4, regs->d5, regs->a0, regs->a1); in show_registers()
859 current->comm, task_pid_nr(current), current); in show_registers()
860 addr = (unsigned long)&fp->un; in show_registers()
861 pr_info("Frame format=%X ", regs->format); in show_registers()
862 switch (regs->format) { in show_registers()
864 pr_cont("instr addr=%08lx\n", fp->un.fmt2.iaddr); in show_registers()
865 addr += sizeof(fp->un.fmt2); in show_registers()
868 pr_cont("eff addr=%08lx\n", fp->un.fmt3.effaddr); in show_registers()
869 addr += sizeof(fp->un.fmt3); in show_registers()
874 fp->un.fmt4.effaddr, fp->un.fmt4.pc); in show_registers()
876 pr_cont("eff addr=%08lx pc=%08lx\n", in show_registers()
877 fp->un.fmt4.effaddr, fp->un.fmt4.pc); in show_registers()
878 addr += sizeof(fp->un.fmt4); in show_registers()
882 fp->un.fmt7.effaddr, fp->un.fmt7.ssw, fp->un.fmt7.faddr); in show_registers()
884 fp->un.fmt7.wb1s, fp->un.fmt7.wb1a, fp->un.fmt7.wb1dpd0); in show_registers()
886 fp->un.fmt7.wb2s, fp->un.fmt7.wb2a, fp->un.fmt7.wb2d); in show_registers()
888 fp->un.fmt7.wb3s, fp->un.fmt7.wb3a, fp->un.fmt7.wb3d); in show_registers()
890 fp->un.fmt7.wb1dpd0, fp->un.fmt7.pd1, fp->un.fmt7.pd2, in show_registers()
891 fp->un.fmt7.pd3); in show_registers()
892 addr += sizeof(fp->un.fmt7); in show_registers()
895 pr_cont("instr addr=%08lx\n", fp->un.fmt9.iaddr); in show_registers()
896 addr += sizeof(fp->un.fmt9); in show_registers()
900 fp->un.fmta.ssw, fp->un.fmta.isc, fp->un.fmta.isb, in show_registers()
901 fp->un.fmta.daddr, fp->un.fmta.dobuf); in show_registers()
902 addr += sizeof(fp->un.fmta); in show_registers()
906 fp->un.fmtb.ssw, fp->un.fmtb.isc, fp->un.fmtb.isb, in show_registers()
907 fp->un.fmtb.daddr, fp->un.fmtb.dobuf); in show_registers()
909 fp->un.fmtb.baddr, fp->un.fmtb.dibuf, fp->un.fmtb.ver); in show_registers()
910 addr += sizeof(fp->un.fmtb); in show_registers()
918 cp = (u16 *)regs->pc; in show_registers()
919 for (i = -8; i < 16; i++) { in show_registers()
921 pr_cont(" Bad PC value."); in show_registers()
941 stack = (unsigned long *)task->thread.esp0; in show_stack()
945 endstack = (unsigned long *)(((unsigned long)stack + THREAD_SIZE - 1) & -THREAD_SIZE); in show_stack()
970 int vector = (fp->ptregs.vector >> 2) & 0xff; in bad_super_trap()
976 fp->ptregs.format); in bad_super_trap()
979 vector, fp->ptregs.format); in bad_super_trap()
981 unsigned short ssw = fp->un.fmtb.ssw; in bad_super_trap()
987 (fp->ptregs.format) == 0xA ? in bad_super_trap()
988 fp->ptregs.pc + 2 : fp->un.fmtb.baddr - 2); in bad_super_trap()
991 (fp->ptregs.format) == 0xA ? in bad_super_trap()
992 fp->ptregs.pc + 4 : fp->un.fmtb.baddr); in bad_super_trap()
994 pr_err("Data %s fault at %#010lx in %s (pc=%#lx)\n", in bad_super_trap()
995 ssw & RW ? "read" : "write", in bad_super_trap()
996 fp->un.fmtb.daddr, space_names[ssw & DFC], in bad_super_trap()
997 fp->ptregs.pc); in bad_super_trap()
1000 die_if_kernel("BAD KERNEL TRAP", &fp->ptregs, 0); in bad_super_trap()
1007 int vector = (fp->ptregs.vector >> 2) & 0xff; in trap_c()
1009 if (fp->ptregs.sr & PS_S) { in trap_c()
1017 if (fixup_exception(&fp->ptregs)) in trap_c()
1105 switch (fp->ptregs.format) { in trap_c()
1107 addr = (void __user *) fp->ptregs.pc; in trap_c()
1110 addr = (void __user *) fp->un.fmt2.iaddr; in trap_c()
1113 addr = (void __user *) fp->un.fmt7.effaddr; in trap_c()
1116 addr = (void __user *) fp->un.fmt9.iaddr; in trap_c()
1119 addr = (void __user *) fp->un.fmta.daddr; in trap_c()
1122 addr = (void __user*) fp->un.fmtb.daddr; in trap_c()
1130 if (!(fp->sr & PS_S)) in die_if_kernel()
1142 current->thread.esp0 = ssp; in set_esp0()
1147 * user-space from the fpsp040 code.