Changes in / [5b7a107:df58e44] in mainline
- Location:
- kernel/generic
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/include/proc/thread.h
r5b7a107 rdf58e44 140 140 bool interrupted; 141 141 142 /** 143 * If true, the scheduler will print a stack trace 144 * to the kernel console upon scheduling this thread. 145 */ 146 bool btrace; 147 142 148 /** If true, thread_join_timeout() cannot be used on this thread. */ 143 149 bool detached; … … 190 196 191 197 #ifdef CONFIG_UDEBUG 192 /**193 * If true, the scheduler will print a stack trace194 * to the kernel console upon scheduling this thread.195 */196 bool btrace;197 198 198 /** Debugging stuff */ 199 199 udebug_thread_t udebug; … … 245 245 extern void thread_update_accounting(bool); 246 246 extern bool thread_exists(thread_t *); 247 248 #ifdef CONFIG_UDEBUG249 247 extern void thread_stack_trace(thread_id_t); 250 #endif251 248 252 249 /** Fpu context slab cache. */ -
kernel/generic/src/console/cmd.c
r5b7a107 rdf58e44 111 111 112 112 #ifdef CONFIG_TEST 113 114 113 /* Data and methods for 'test' command. */ 115 114 static char test_buf[MAX_CMDLINE + 1]; … … 149 148 .argv = bench_argv 150 149 }; 151 152 #endif /* CONFIG_TEST */ 150 #endif 153 151 154 152 /* Data and methods for 'description' command. */ … … 385 383 }; 386 384 387 #ifdef CONFIG_UDEBUG388 389 385 /* Data and methods for 'btrace' command */ 390 386 static int cmd_btrace(cmd_arg_t *argv); … … 399 395 .argv = &btrace_argv 400 396 }; 401 402 #endif /* CONFIG_UDEBUG */403 397 404 398 static int cmd_sched(cmd_arg_t *argv); … … 498 492 499 493 static cmd_info_t *basic_commands[] = { 494 &btrace_info, 500 495 &call0_info, 501 496 &mcall0_info, … … 528 523 &bench_info, 529 524 #endif 530 #ifdef CONFIG_UDEBUG531 &btrace_info,532 #endif533 525 NULL 534 526 }; … … 988 980 } 989 981 990 #ifdef CONFIG_UDEBUG991 992 982 /** Command for printing thread stack trace 993 983 * … … 1002 992 return 1; 1003 993 } 1004 1005 #endif /* CONFIG_UDEBUG */1006 994 1007 995 /** Command for printing scheduler information -
kernel/generic/src/proc/scheduler.c
r5b7a107 rdf58e44 102 102 #endif 103 103 104 #ifdef CONFIG_UDEBUG105 104 if (THREAD->btrace) { 106 105 istate_t *istate = THREAD->udebug.uspace_state; … … 112 111 THREAD->btrace = false; 113 112 } 114 #endif115 113 } 116 114 -
kernel/generic/src/proc/thread.c
r5b7a107 rdf58e44 338 338 339 339 thread->interrupted = false; 340 thread->btrace = false; 340 341 thread->detached = false; 341 342 waitq_initialize(&thread->join_wq); … … 350 351 351 352 #ifdef CONFIG_UDEBUG 352 /* Initialize debugging stuff */ 353 thread->btrace = false; 353 /* Init debugging stuff */ 354 354 udebug_thread_initialize(&thread->udebug); 355 355 #endif … … 752 752 } 753 753 754 #ifdef CONFIG_UDEBUG755 756 754 void thread_stack_trace(thread_id_t thread_id) 757 755 { … … 796 794 irq_spinlock_unlock(&threads_lock, true); 797 795 } 798 799 #endif /* CONFIG_UDEBUG */800 796 801 797 /** Process syscall to create new thread.
Note:
See TracChangeset
for help on using the changeset viewer.