|
@@ -20,8 +20,6 @@
|
|
#include <asm/system.h>
|
|
#include <asm/system.h>
|
|
#include <asm/pgtable.h>
|
|
#include <asm/pgtable.h>
|
|
|
|
|
|
-extern void die_if_kernel(char *, struct pt_regs *, long);
|
|
|
|
-
|
|
|
|
/*
|
|
/*
|
|
* This routine handles page faults. It determines the problem, and
|
|
* This routine handles page faults. It determines the problem, and
|
|
* then passes it off to one of the appropriate routines.
|
|
* then passes it off to one of the appropriate routines.
|
|
@@ -50,7 +48,8 @@ asmlinkage int do_page_fault(struct pt_regs *regs, unsigned long address,
|
|
} else
|
|
} else
|
|
printk(KERN_ALERT "Unable to handle kernel access");
|
|
printk(KERN_ALERT "Unable to handle kernel access");
|
|
printk(" at virtual address %08lx\n",address);
|
|
printk(" at virtual address %08lx\n",address);
|
|
- die_if_kernel("Oops", regs, error_code);
|
|
|
|
|
|
+ if (!user_mode(regs))
|
|
|
|
+ die("Oops", regs, error_code);
|
|
do_exit(SIGKILL);
|
|
do_exit(SIGKILL);
|
|
|
|
|
|
return 1;
|
|
return 1;
|