1 #ifndef _SPARC_PTRACE_H
2 #define _SPARC_PTRACE_H
3
4 /* I have not looked enough into how this should be done. Without playing
5 * lots of tricks to optimize I think we need to save the whole register
6 * window frame plus the floating-point registers. We'll see...
7 */
8
9 /* this struct defines the way the registers are stored on the
10 stack during a system call. */
11
12 struct pt_regs {
13 unsigned long psr; /* for condition codes */
14 unsigned long pc; /* current and next program counter */
15 unsigned long npc;
16 unsigned long y;
17 /* not sure yet whether all regs are necessary
18 * but this is how it is traditionally done on the sparc.
19 */
20 unsigned long u_regs[16]; /* globals and ins */
21 };
22
23 #ifdef __KERNEL__
24 /* if previous supervisor is 0, came from user */
25 #define user_mode(regs) (0x0)
26 extern void show_regs(struct pt_regs *);
27 #endif
28
29 #endif