diff options
Diffstat (limited to 'kernel/debug/debug_core.h')
| -rw-r--r-- | kernel/debug/debug_core.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/kernel/debug/debug_core.h b/kernel/debug/debug_core.h index db554f9be51..44cf3de8cf9 100644 --- a/kernel/debug/debug_core.h +++ b/kernel/debug/debug_core.h | |||
| @@ -38,6 +38,8 @@ struct debuggerinfo_struct { | |||
| 38 | void *debuggerinfo; | 38 | void *debuggerinfo; |
| 39 | struct task_struct *task; | 39 | struct task_struct *task; |
| 40 | int exception_state; | 40 | int exception_state; |
| 41 | int ret_state; | ||
| 42 | int irq_depth; | ||
| 41 | }; | 43 | }; |
| 42 | 44 | ||
| 43 | extern struct debuggerinfo_struct kgdb_info[]; | 45 | extern struct debuggerinfo_struct kgdb_info[]; |
| @@ -47,9 +49,31 @@ extern int dbg_remove_all_break(void); | |||
| 47 | extern int dbg_set_sw_break(unsigned long addr); | 49 | extern int dbg_set_sw_break(unsigned long addr); |
| 48 | extern int dbg_remove_sw_break(unsigned long addr); | 50 | extern int dbg_remove_sw_break(unsigned long addr); |
| 49 | extern int dbg_activate_sw_breakpoints(void); | 51 | extern int dbg_activate_sw_breakpoints(void); |
| 52 | extern int dbg_deactivate_sw_breakpoints(void); | ||
| 53 | |||
| 54 | /* polled character access to i/o module */ | ||
| 55 | extern int dbg_io_get_char(void); | ||
| 56 | |||
| 57 | /* stub return value for switching between the gdbstub and kdb */ | ||
| 58 | #define DBG_PASS_EVENT -12345 | ||
| 59 | /* Switch from one cpu to another */ | ||
| 60 | #define DBG_SWITCH_CPU_EVENT -123456 | ||
| 61 | extern int dbg_switch_cpu; | ||
| 50 | 62 | ||
| 51 | /* gdbstub interface functions */ | 63 | /* gdbstub interface functions */ |
| 52 | extern int gdb_serial_stub(struct kgdb_state *ks); | 64 | extern int gdb_serial_stub(struct kgdb_state *ks); |
| 53 | extern void gdbstub_msg_write(const char *s, int len); | 65 | extern void gdbstub_msg_write(const char *s, int len); |
| 54 | 66 | ||
| 67 | /* gdbstub functions used for kdb <-> gdbstub transition */ | ||
| 68 | extern int gdbstub_state(struct kgdb_state *ks, char *cmd); | ||
| 69 | |||
| 70 | #ifdef CONFIG_KGDB_KDB | ||
| 71 | extern int kdb_stub(struct kgdb_state *ks); | ||
| 72 | #else /* ! CONFIG_KGDB_KDB */ | ||
| 73 | static inline int kdb_stub(struct kgdb_state *ks) | ||
| 74 | { | ||
| 75 | return DBG_PASS_EVENT; | ||
| 76 | } | ||
| 77 | #endif /* CONFIG_KGDB_KDB */ | ||
| 78 | |||
| 55 | #endif /* _DEBUG_CORE_H_ */ | 79 | #endif /* _DEBUG_CORE_H_ */ |
