aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-sparc64/ptrace.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-sparc64/ptrace.h')
-rw-r--r--include/asm-sparc64/ptrace.h10
1 files changed, 4 insertions, 6 deletions
diff --git a/include/asm-sparc64/ptrace.h b/include/asm-sparc64/ptrace.h
index 823656559d1a..90972a5ada59 100644
--- a/include/asm-sparc64/ptrace.h
+++ b/include/asm-sparc64/ptrace.h
@@ -42,16 +42,14 @@ static inline int pt_regs_trap_type(struct pt_regs *regs)
42 return regs->magic & 0x1ff; 42 return regs->magic & 0x1ff;
43} 43}
44 44
45static inline int pt_regs_clear_trap_type(struct pt_regs *regs) 45static inline bool pt_regs_is_syscall(struct pt_regs *regs)
46{ 46{
47 return regs->magic &= ~0x1ff; 47 return (regs->tstate & TSTATE_SYSCALL);
48} 48}
49 49
50static inline bool pt_regs_is_syscall(struct pt_regs *regs) 50static inline bool pt_regs_clear_syscall(struct pt_regs *regs)
51{ 51{
52 int tt = pt_regs_trap_type(regs); 52 return (regs->tstate &= ~TSTATE_SYSCALL);
53
54 return (tt == 0x110 || tt == 0x111 || tt == 0x16d);
55} 53}
56 54
57struct pt_regs32 { 55struct pt_regs32 {