Rev 2919 | Rev 3014 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 2919 | Rev 2921 | ||
|---|---|---|---|
| Line 143... | Line 143... | ||
| 143 | UDEBUG_EVENT_STOP, /**< Stopped on DEBUG_STOP request */ |
143 | UDEBUG_EVENT_STOP, /**< Stopped on DEBUG_STOP request */ |
| 144 | UDEBUG_EVENT_SYSCALL_B, /**< Before beginning syscall execution */ |
144 | UDEBUG_EVENT_SYSCALL_B, /**< Before beginning syscall execution */ |
| 145 | UDEBUG_EVENT_SYSCALL_E, /**< After finishing syscall execution */ |
145 | UDEBUG_EVENT_SYSCALL_E, /**< After finishing syscall execution */ |
| 146 | UDEBUG_EVENT_THREAD_B, /**< The task created a new thread */ |
146 | UDEBUG_EVENT_THREAD_B, /**< The task created a new thread */ |
| 147 | UDEBUG_EVENT_THREAD_E, /**< A thread exited */ |
147 | UDEBUG_EVENT_THREAD_E, /**< A thread exited */ |
| 148 | UDEBUG_EVENT_BREAKPOINT /**< Breakpoint instruction executed */ |
148 | UDEBUG_EVENT_BREAKPOINT, /**< Breakpoint instruction executed */ |
| - | 149 | UDEBUG_EVENT_TRAP /**< Single-step trap */ |
|
| 149 | } udebug_event_t; |
150 | } udebug_event_t; |
| 150 | 151 | ||
| 151 | #define UDEBUG_EVMASK(event) (1 << ((event) - 1)) |
152 | #define UDEBUG_EVMASK(event) (1 << ((event) - 1)) |
| 152 | 153 | ||
| 153 | typedef enum { |
154 | typedef enum { |
| Line 156... | Line 157... | ||
| 156 | UDEBUG_EM_SYSCALL_B = UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_B), |
157 | UDEBUG_EM_SYSCALL_B = UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_B), |
| 157 | UDEBUG_EM_SYSCALL_E = UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_E), |
158 | UDEBUG_EM_SYSCALL_E = UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_E), |
| 158 | UDEBUG_EM_THREAD_B = UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_B), |
159 | UDEBUG_EM_THREAD_B = UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_B), |
| 159 | UDEBUG_EM_THREAD_E = UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_E), |
160 | UDEBUG_EM_THREAD_E = UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_E), |
| 160 | UDEBUG_EM_BREAKPOINT = UDEBUG_EVMASK(UDEBUG_EVENT_BREAKPOINT), |
161 | UDEBUG_EM_BREAKPOINT = UDEBUG_EVMASK(UDEBUG_EVENT_BREAKPOINT), |
| - | 162 | UDEBUG_EM_TRAP = UDEBUG_EVMASK(UDEBUG_EVENT_TRAP), |
|
| 161 | UDEBUG_EM_ALL = |
163 | UDEBUG_EM_ALL = |
| 162 | UDEBUG_EVMASK(UDEBUG_EVENT_FINISHED) | |
164 | UDEBUG_EVMASK(UDEBUG_EVENT_FINISHED) | |
| 163 | UDEBUG_EVMASK(UDEBUG_EVENT_STOP) | |
165 | UDEBUG_EVMASK(UDEBUG_EVENT_STOP) | |
| 164 | UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_B) | |
166 | UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_B) | |
| 165 | UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_E) | |
167 | UDEBUG_EVMASK(UDEBUG_EVENT_SYSCALL_E) | |
| 166 | UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_B) | |
168 | UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_B) | |
| 167 | UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_E) | |
169 | UDEBUG_EVMASK(UDEBUG_EVENT_THREAD_E) | |
| 168 | UDEBUG_EVMASK(UDEBUG_EVENT_BREAKPOINT) |
170 | UDEBUG_EVMASK(UDEBUG_EVENT_BREAKPOINT) | |
| - | 171 | UDEBUG_EVMASK(UDEBUG_EVENT_TRAP) |
|
| 169 | } udebug_evmask_t; |
172 | } udebug_evmask_t; |
| 170 | 173 | ||
| 171 | #ifdef KERNEL |
174 | #ifdef KERNEL |
| 172 | 175 | ||
| 173 | typedef enum { |
176 | typedef enum { |
| Line 193... | Line 196... | ||
| 193 | 196 | ||
| 194 | void udebug_stoppable_begin(void); |
197 | void udebug_stoppable_begin(void); |
| 195 | void udebug_stoppable_end(void); |
198 | void udebug_stoppable_end(void); |
| 196 | 199 | ||
| 197 | void udebug_breakpoint_event(uintptr_t addr); |
200 | void udebug_breakpoint_event(uintptr_t addr); |
| - | 201 | void udebug_trap_event(uintptr_t addr); |
|
| 198 | 202 | ||
| 199 | int udebug_task_cleanup(struct task *ta); |
203 | int udebug_task_cleanup(struct task *ta); |
| 200 | 204 | ||
| 201 | #endif |
205 | #endif |
| 202 | 206 | ||