Lines Matching refs:regs

117 	show_trace((unsigned long *)tsk->thread.regs.ksp);  in show_trace_task()
156 void show_regs(struct pt_regs *regs) in show_regs() argument
164 level = user_mode(regs) ? KERN_DEBUG : KERN_CRIT; in show_regs()
169 printbinary(buf, regs->gr[0], 32); in show_regs()
177 p += sprintf(p, " " RFMT, (i+j) == 0 ? 0 : regs->gr[i + j]); in show_regs()
187 p += sprintf(p, " " RFMT, regs->sr[i + j]); in show_regs()
195 regs->fr[i], i+1, regs->fr[i+1]); in show_regs()
202 level, regs->iasq[0], regs->iasq[1], regs->iaoq[0], regs->iaoq[1]); in show_regs()
204 level, regs->iir, regs->isr, regs->ior); in show_regs()
207 printk("%s ORIG_R28: " RFMT "\n", level, regs->orig_r28); in show_regs()
211 void die_if_kernel(char *str, struct pt_regs *regs, long err) in die_if_kernel() argument
213 if (user_mode(regs)) { in die_if_kernel()
221 show_regs(regs); in die_if_kernel()
238 show_regs(regs); in die_if_kernel()
251 int syscall_ipi(int (*syscall) (struct pt_regs *), struct pt_regs *regs) in syscall_ipi() argument
253 return syscall(regs); in syscall_ipi()
258 void handle_gdb_break(struct pt_regs *regs, int wot) in handle_gdb_break() argument
263 si.si_addr = (void *) (regs->iaoq[0] & ~3); in handle_gdb_break()
269 void handle_break(unsigned iir, struct pt_regs *regs) in handle_break() argument
279 die_if_kernel("Breakpoint", regs, 0); in handle_break()
281 show_regs(regs); in handle_break()
284 si.si_addr = (void *) (regs->iaoq[0] & ~3); in handle_break()
290 die_if_kernel("Breakpoint", regs, 0); in handle_break()
291 handle_gdb_break(regs, TRAP_BRKPT); in handle_break()
298 show_regs(regs); in handle_break()
302 si.si_addr = (void *) (regs->iaoq[0] & ~3); in handle_break()
315 static void default_trap(int code, struct pt_regs *regs) in default_trap() argument
318 show_regs(regs); in default_trap()
321 void (*cpu_lpmc) (int code, struct pt_regs *regs) = default_trap;
324 void transfer_pim_to_trap_frame(struct pt_regs *regs) in transfer_pim_to_trap_frame() argument
342 regs->gr[0] = pim_wide->cr[22]; in transfer_pim_to_trap_frame()
345 regs->gr[i] = pim_wide->gr[i]; in transfer_pim_to_trap_frame()
348 regs->fr[i] = pim_wide->fr[i]; in transfer_pim_to_trap_frame()
351 regs->sr[i] = pim_wide->sr[i]; in transfer_pim_to_trap_frame()
353 regs->iasq[0] = pim_wide->cr[17]; in transfer_pim_to_trap_frame()
354 regs->iasq[1] = pim_wide->iasq_back; in transfer_pim_to_trap_frame()
355 regs->iaoq[0] = pim_wide->cr[18]; in transfer_pim_to_trap_frame()
356 regs->iaoq[1] = pim_wide->iaoq_back; in transfer_pim_to_trap_frame()
358 regs->sar = pim_wide->cr[11]; in transfer_pim_to_trap_frame()
359 regs->iir = pim_wide->cr[19]; in transfer_pim_to_trap_frame()
360 regs->isr = pim_wide->cr[20]; in transfer_pim_to_trap_frame()
361 regs->ior = pim_wide->cr[21]; in transfer_pim_to_trap_frame()
366 regs->gr[0] = pim_narrow->cr[22]; in transfer_pim_to_trap_frame()
369 regs->gr[i] = pim_narrow->gr[i]; in transfer_pim_to_trap_frame()
372 regs->fr[i] = pim_narrow->fr[i]; in transfer_pim_to_trap_frame()
375 regs->sr[i] = pim_narrow->sr[i]; in transfer_pim_to_trap_frame()
377 regs->iasq[0] = pim_narrow->cr[17]; in transfer_pim_to_trap_frame()
378 regs->iasq[1] = pim_narrow->iasq_back; in transfer_pim_to_trap_frame()
379 regs->iaoq[0] = pim_narrow->cr[18]; in transfer_pim_to_trap_frame()
380 regs->iaoq[1] = pim_narrow->iaoq_back; in transfer_pim_to_trap_frame()
382 regs->sar = pim_narrow->cr[11]; in transfer_pim_to_trap_frame()
383 regs->iir = pim_narrow->cr[19]; in transfer_pim_to_trap_frame()
384 regs->isr = pim_narrow->cr[20]; in transfer_pim_to_trap_frame()
385 regs->ior = pim_narrow->cr[21]; in transfer_pim_to_trap_frame()
393 regs->ksp = 0; in transfer_pim_to_trap_frame()
394 regs->kpc = 0; in transfer_pim_to_trap_frame()
395 regs->orig_r28 = 0; in transfer_pim_to_trap_frame()
404 void parisc_terminate(char *msg, struct pt_regs *regs, int code, unsigned long offset) in parisc_terminate() argument
424 transfer_pim_to_trap_frame(regs); in parisc_terminate()
432 show_stack((unsigned long *)regs->gr[30]); in parisc_terminate()
436 msg, code, regs, offset); in parisc_terminate()
437 show_regs(regs); in parisc_terminate()
452 void handle_interruption(int code, struct pt_regs *regs) in handle_interruption() argument
468 regs, code, 0); in handle_interruption()
478 regs->gr[0] &= ~PSW_R; in handle_interruption()
479 if (regs->iasq[0]) in handle_interruption()
480 handle_gdb_break(regs, TRAP_TRACE); in handle_interruption()
490 cpu_lpmc(5, regs); in handle_interruption()
495 fault_address = regs->iaoq[0]; in handle_interruption()
496 fault_space = regs->iasq[0]; in handle_interruption()
501 die_if_kernel("Illegal instruction", regs, code); in handle_interruption()
507 handle_break(regs->iir,regs); in handle_interruption()
512 die_if_kernel("Privileged operation", regs, code); in handle_interruption()
518 if ((regs->iir & 0xffdfffe0) == 0x034008a0) { in handle_interruption()
524 if (regs->iir & 0x00200000) in handle_interruption()
525 regs->gr[regs->iir & 0x1f] = mfctl(27); in handle_interruption()
527 regs->gr[regs->iir & 0x1f] = mfctl(26); in handle_interruption()
529 regs->iaoq[0] = regs->iaoq[1]; in handle_interruption()
530 regs->iaoq[1] += 4; in handle_interruption()
531 regs->iasq[0] = regs->iasq[1]; in handle_interruption()
535 die_if_kernel("Privileged register usage", regs, code); in handle_interruption()
541 si.si_addr = (void *) regs->iaoq[0]; in handle_interruption()
549 si.si_addr = (void *) regs->iaoq[0]; in handle_interruption()
560 si.si_addr = (void *) regs->iaoq[0]; in handle_interruption()
566 die_if_kernel("Floating point exception", regs, 0); /* quiet */ in handle_interruption()
567 handle_fpe(regs); in handle_interruption()
583 fault_address = regs->ior; in handle_interruption()
584 fault_space = regs->isr; in handle_interruption()
590 if (check_unaligned(regs)) { in handle_interruption()
591 handle_unaligned(regs); in handle_interruption()
597 fault_address = regs->ior; in handle_interruption()
598 fault_space = regs->isr; in handle_interruption()
603 regs->gr[0] |= PSW_X; /* So we can single-step over the trap */ in handle_interruption()
607 handle_gdb_break(regs, TRAP_HWBKPT); in handle_interruption()
612 regs->gr[0] &= ~PSW_T; in handle_interruption()
613 if (regs->iasq[0]) in handle_interruption()
614 handle_gdb_break(regs, TRAP_BRANCH); in handle_interruption()
635 if (user_mode(regs)) { in handle_interruption()
639 vma = find_vma(current->mm,regs->iaoq[0]); in handle_interruption()
640 if (vma && (regs->iaoq[0] >= vma->vm_start) in handle_interruption()
643 fault_address = regs->iaoq[0]; in handle_interruption()
644 fault_space = regs->iasq[0]; in handle_interruption()
654 die_if_kernel("Protection id trap", regs, code); in handle_interruption()
659 si.si_addr = (void *) regs->iaoq[0]; in handle_interruption()
661 si.si_addr = (void *) regs->ior; in handle_interruption()
667 handle_unaligned(regs); in handle_interruption()
671 if (user_mode(regs)) { in handle_interruption()
675 show_regs(regs); in handle_interruption()
681 si.si_addr = (void *) regs->ior; in handle_interruption()
688 parisc_terminate("Unexpected interruption", regs, code, 0); in handle_interruption()
692 if (user_mode(regs)) { in handle_interruption()
693 if (fault_space != regs->sr[7]) { in handle_interruption()
700 show_regs(regs); in handle_interruption()
705 si.si_addr = (void *) regs->ior; in handle_interruption()
718 parisc_terminate("Kernel Fault", regs, code, fault_address); in handle_interruption()
724 do_page_fault(regs, code, fault_address); in handle_interruption()