提交 2d911e9a 编写于 作者: R Ralf Baechle

[MIPS] Move die and die_if_kernel() from system.h to ptrace.h

This eleminates the need to include ptrace.h into system.h and fixes a
harmless namespace conflict on the PC symbol in bpck.c.
Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
上级 86384d54
...@@ -82,6 +82,14 @@ struct pt_regs { ...@@ -82,6 +82,14 @@ struct pt_regs {
extern asmlinkage void do_syscall_trace(struct pt_regs *regs, int entryexit); 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
#endif /* _ASM_PTRACE_H */ #endif /* _ASM_PTRACE_H */
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include <asm/barrier.h> #include <asm/barrier.h>
#include <asm/cpu-features.h> #include <asm/cpu-features.h>
#include <asm/dsp.h> #include <asm/dsp.h>
#include <asm/ptrace.h>
#include <asm/war.h> #include <asm/war.h>
...@@ -336,14 +335,6 @@ extern void *set_except_vector(int n, void *addr); ...@@ -336,14 +335,6 @@ extern void *set_except_vector(int n, void *addr);
extern unsigned long ebase; extern unsigned long ebase;
extern void per_cpu_trap_init(void); extern void per_cpu_trap_init(void);
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);
}
extern int stop_a_enabled; extern int stop_a_enabled;
/* /*
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册