Changes in / [5b7a107:df58e44] in mainline


Ignore:
Location:
kernel/generic
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/include/proc/thread.h

    r5b7a107 rdf58e44  
    140140        bool interrupted;
    141141       
     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       
    142148        /** If true, thread_join_timeout() cannot be used on this thread. */
    143149        bool detached;
     
    190196       
    191197#ifdef CONFIG_UDEBUG
    192         /**
    193          * If true, the scheduler will print a stack trace
    194          * to the kernel console upon scheduling this thread.
    195          */
    196         bool btrace;
    197        
    198198        /** Debugging stuff */
    199199        udebug_thread_t udebug;
     
    245245extern void thread_update_accounting(bool);
    246246extern bool thread_exists(thread_t *);
    247 
    248 #ifdef CONFIG_UDEBUG
    249247extern void thread_stack_trace(thread_id_t);
    250 #endif
    251248
    252249/** Fpu context slab cache. */
  • kernel/generic/src/console/cmd.c

    r5b7a107 rdf58e44  
    111111
    112112#ifdef CONFIG_TEST
    113 
    114113/* Data and methods for 'test' command. */
    115114static char test_buf[MAX_CMDLINE + 1];
     
    149148        .argv = bench_argv
    150149};
    151 
    152 #endif /* CONFIG_TEST */
     150#endif
    153151
    154152/* Data and methods for 'description' command. */
     
    385383};
    386384
    387 #ifdef CONFIG_UDEBUG
    388 
    389385/* Data and methods for 'btrace' command */
    390386static int cmd_btrace(cmd_arg_t *argv);
     
    399395        .argv = &btrace_argv
    400396};
    401 
    402 #endif /* CONFIG_UDEBUG */
    403397
    404398static int cmd_sched(cmd_arg_t *argv);
     
    498492
    499493static cmd_info_t *basic_commands[] = {
     494        &btrace_info,
    500495        &call0_info,
    501496        &mcall0_info,
     
    528523        &bench_info,
    529524#endif
    530 #ifdef CONFIG_UDEBUG
    531         &btrace_info,
    532 #endif
    533525        NULL
    534526};
     
    988980}
    989981
    990 #ifdef CONFIG_UDEBUG
    991 
    992982/** Command for printing thread stack trace
    993983 *
     
    1002992        return 1;
    1003993}
    1004 
    1005 #endif /* CONFIG_UDEBUG */
    1006994
    1007995/** Command for printing scheduler information
  • kernel/generic/src/proc/scheduler.c

    r5b7a107 rdf58e44  
    102102#endif
    103103       
    104 #ifdef CONFIG_UDEBUG
    105104        if (THREAD->btrace) {
    106105                istate_t *istate = THREAD->udebug.uspace_state;
     
    112111                THREAD->btrace = false;
    113112        }
    114 #endif
    115113}
    116114
  • kernel/generic/src/proc/thread.c

    r5b7a107 rdf58e44  
    338338       
    339339        thread->interrupted = false;
     340        thread->btrace = false;
    340341        thread->detached = false;
    341342        waitq_initialize(&thread->join_wq);
     
    350351       
    351352#ifdef CONFIG_UDEBUG
    352         /* Initialize debugging stuff */
    353         thread->btrace = false;
     353        /* Init debugging stuff */
    354354        udebug_thread_initialize(&thread->udebug);
    355355#endif
     
    752752}
    753753
    754 #ifdef CONFIG_UDEBUG
    755 
    756754void thread_stack_trace(thread_id_t thread_id)
    757755{
     
    796794        irq_spinlock_unlock(&threads_lock, true);
    797795}
    798 
    799 #endif /* CONFIG_UDEBUG */
    800796
    801797/** Process syscall to create new thread.
Note: See TracChangeset for help on using the changeset viewer.