]>
Commit | Line | Data |
---|---|---|
b2441318 | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
1da177e4 LT |
2 | /* written by Philipp Rumpf, Copyright (C) 1999 SuSE GmbH Nuernberg |
3 | ** Copyright (C) 2000 Grant Grundler, Hewlett-Packard | |
4 | */ | |
70c1674f DH |
5 | #ifndef _PARISC_PTRACE_H |
6 | #define _PARISC_PTRACE_H | |
1da177e4 | 7 | |
70c1674f | 8 | #include <uapi/asm/ptrace.h> |
f22ab814 | 9 | |
1da177e4 | 10 | |
f22ab814 AB |
11 | #define task_regs(task) ((struct pt_regs *) ((char *)(task) + TASK_REGS)) |
12 | ||
81e192d6 | 13 | #define arch_has_single_step() 1 |
81e192d6 | 14 | #define arch_has_block_step() 1 |
81e192d6 | 15 | |
1da177e4 LT |
16 | /* XXX should we use iaoq[1] or iaoq[0] ? */ |
17 | #define user_mode(regs) (((regs)->iaoq[0] & 3) ? 1 : 0) | |
18 | #define user_space(regs) (((regs)->iasq[1] != 0) ? 1 : 0) | |
19 | #define instruction_pointer(regs) ((regs)->iaoq[0] & ~3) | |
40e03b68 | 20 | #define user_stack_pointer(regs) ((regs)->gr[30]) |
5cd55b0e | 21 | unsigned long profile_pc(struct pt_regs *); |
40e03b68 | 22 | |
527973c8 HD |
23 | static inline unsigned long regs_return_value(struct pt_regs *regs) |
24 | { | |
25 | return regs->gr[20]; | |
26 | } | |
40e03b68 | 27 | |
1da177e4 | 28 | #endif |