]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/asm-mips/ptrace.h
[MIPS] Add external declaration of pagetable_init() to pgalloc.h
[linux-2.6-omap-h63xx.git] / include / asm-mips / ptrace.h
index 4fb0fc43ffd71af828d8362052612b32b7fcafc1..8a1f2b6f04aca4e4b68fd9b63a2f4a42f7021da0 100644 (file)
@@ -44,9 +44,8 @@ struct pt_regs {
        unsigned long cp0_epc;
 #ifdef CONFIG_MIPS_MT_SMTC
        unsigned long cp0_tcstatus;
-       unsigned long smtc_pad;
 #endif /* CONFIG_MIPS_MT_SMTC */
-};
+} __attribute__ ((aligned (8)));
 
 /* Arbitrarily choose the same ptrace numbers as used by the Sparc code. */
 #define PTRACE_GETREGS         12
@@ -81,10 +80,16 @@ struct pt_regs {
 #define instruction_pointer(regs) ((regs)->cp0_epc)
 #define profile_pc(regs) instruction_pointer(regs)
 
-extern void show_regs(struct pt_regs *);
-
 extern asmlinkage void do_syscall_trace(struct pt_regs *regs, int entryexit);
 
+extern NORET_TYPE void die(const char *, struct pt_regs *);
+
+static inline void die_if_kernel(const char *str, struct pt_regs *regs)
+{
+       if (unlikely(!user_mode(regs)))
+               die(str, regs);
+}
+
 #endif
 
 #endif /* _ASM_PTRACE_H */