1 #ifndef _CRIS_ARCH_PTRACE_H
2 #define _CRIS_ARCH_PTRACE_H
4 /* Register numbers in the ptrace system call interface */
27 #define PT_ERP 21 /* This is actually the debugged process' PC */
30 #define PT_USP 24 /* special case - USP is not in the pt_regs */
31 #define PT_PPC 25 /* special case - pseudo PC */
32 #define PT_BP 26 /* Base number for BP registers. */
33 #define PT_BP_CTRL 26 /* BP control register. */
36 /* Condition code bit numbers. */
47 #define M_CCS_BITNR 30
48 #define Q_CCS_BITNR 31
49 #define CCS_SHIFT 10 /* Shift count for each level in CCS */
51 /* pt_regs not only specifices the format in the user-struct during
52 * ptrace but is also the frame format used in the kernel prologue/epilogues
57 unsigned long orig_r10
;
58 /* pushed by movem r13, [sp] in SAVE_ALL. */
79 unsigned long erp
; /* This is actually the debugged process' PC */
80 /* For debugging purposes; saved only when needed. */
85 /* switch_stack is the extra stuff pushed onto the stack in _resume (entry.S)
86 * when doing a context-switch. it is used (apart from in resume) when a new
87 * thread is made and we need to make _resume (which is starting it for the
88 * first time) realise what is going on.
90 * Actually, the use is very close to the thread struct (TSS) in that both the
91 * switch_stack and the TSS are used to keep thread stuff when switching in
106 unsigned long return_ip
; /* ip that _resume will return to */
109 #define user_mode(regs) (((regs)->ccs & (1 << (U_CCS_BITNR + CCS_SHIFT))) != 0)
110 #define instruction_pointer(regs) ((regs)->erp)
111 extern void show_regs(struct pt_regs
*);
112 #define profile_pc(regs) instruction_pointer(regs)