kernels/linux-2.4.0/arch/ppc/mm/fault.c
/*
 * bad_page_fault is called when we have a bad access from the kernel.
 * It is called from do_page_fault above and from some of the procedures
 * in traps.c.
 */
bad_page_fault is called when we have a bad access from the kernel.
It is called from do_page_fault above and from some of the procedures
in traps.c.
bad_page_fault is called when we have a bad access from the kernel . It is called from do_page_fault above and from some of the procedures in traps . c .
void
bad_page_fault(struct pt_regs *regs, unsigned long address)
{
	unsigned long fixup;
	if ((fixup = search_exception_table(regs->nip)) != 0) {
		regs->nip = fixup;
		return;
	}
	show_regs(regs);
#if defined(CONFIG_XMON) || defined(CONFIG_KGDB)
	if (debugger_kernel_faults)
		debugger(regs);
#endif
	print_backtrace( (unsigned long *)regs->gpr[1] );
	panic("kernel access of bad area pc %lx lr %lx address %lX tsk %s/%d",
	      regs->nip,regs->link,address,current->comm,current->pid);
}
void bad_page_fault ( struct pt_regs * regs , unsigned long address ) { unsigned long fixup ; if ( ( fixup = search_exception_table ( regs -> nip ) ) != 0 ) { regs -> nip = fixup ; return ; } show_regs ( regs ) ; #if defined ( CONFIG_XMON ) || defined ( CONFIG_KGDB ) if ( debugger_kernel_faults ) debugger ( regs ) ; #endif print_backtrace ( ( unsigned long * ) regs -> gpr [ 1 ] ) ; panic ( " " , regs -> nip , regs -> link , address , current -> comm , current -> pid ) ; }
bad_page_fault is called when we have a bad access from the kernel.
bad_page_fault is called when we have a bad access from the kernel .
/* Are we prepared to handle this fault?  */ /* kernel has accessed a bad area */