Changeset acf37bc in mainline for kernel/generic/src/udebug/udebug.c
- Timestamp:
- 2009-05-15T20:22:26Z (16 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 687246b
- Parents:
- 40a0e504
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/udebug/udebug.c
r40a0e504 racf37bc 99 99 } 100 100 101 /** Do a preliminary check that a debugging session is in progress.102 *103 * This only requires the THREAD->udebug.lock mutex (and not TASK->udebug.lock104 * mutex). For an undebugged task, this will never block (while there could be105 * collisions by different threads on the TASK mutex), thus improving SMP106 * perormance for undebugged tasks.107 *108 * @return True if the thread was in a debugging session when the function109 * checked, false otherwise.110 */111 static bool udebug_thread_precheck(void)112 {113 bool res;114 115 mutex_lock(&THREAD->udebug.lock);116 res = THREAD->udebug.active;117 mutex_unlock(&THREAD->udebug.lock);118 119 return res;120 }121 122 101 /** Start of stoppable section. 123 102 * … … 245 224 246 225 etype = end_variant ? UDEBUG_EVENT_SYSCALL_E : UDEBUG_EVENT_SYSCALL_B; 247 248 /* Early check for undebugged tasks */249 if (!udebug_thread_precheck()) {250 return;251 }252 226 253 227 mutex_lock(&TASK->udebug.lock);
Note:
See TracChangeset
for help on using the changeset viewer.