Subversion Repositories HelenOS

Rev

Rev 2502 | Rev 2790 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2502 Rev 2504
Line 575... Line 575...
575
    THREAD->call_me_with = call_me_with;
575
    THREAD->call_me_with = call_me_with;
576
    spinlock_unlock(&THREAD->lock);
576
    spinlock_unlock(&THREAD->lock);
577
    interrupts_restore(ipl);
577
    interrupts_restore(ipl);
578
}
578
}
579
 
579
 
580
static void thread_walker(avltree_node_t *node)
580
static bool thread_walker(avltree_node_t *node, void *arg)
581
{
581
{
582
    thread_t *t;
582
    thread_t *t;
583
       
583
       
584
    t = avltree_get_instance(node, thread_t, threads_tree_node);
584
    t = avltree_get_instance(node, thread_t, threads_tree_node);
585
 
585
 
Line 598... Line 598...
598
           
598
           
599
    if (t->state == Sleeping)
599
    if (t->state == Sleeping)
600
        printf(" %#10zx", t->sleep_queue);
600
        printf(" %#10zx", t->sleep_queue);
601
           
601
           
602
    printf("\n");
602
    printf("\n");
-
 
603
 
-
 
604
    return true;
603
}
605
}
604
 
606
 
605
/** Print list of threads debug info */
607
/** Print list of threads debug info */
606
void thread_print_list(void)
608
void thread_print_list(void)
607
{
609
{
Line 614... Line 616...
614
    printf("tid    name       address    state    task       ctx code    "
616
    printf("tid    name       address    state    task       ctx code    "
615
        "   stack      cycles     cpu  waitqueue\n");
617
        "   stack      cycles     cpu  waitqueue\n");
616
    printf("------ ---------- ---------- -------- ---------- --- --------"
618
    printf("------ ---------- ---------- -------- ---------- --- --------"
617
        "-- ---------- ---------- ---- ---------\n");
619
        "-- ---------- ---------- ---- ---------\n");
618
 
620
 
619
    avltree_walk(&threads_tree, thread_walker);
621
    avltree_walk(&threads_tree, thread_walker, NULL);
620
 
622
 
621
    spinlock_unlock(&threads_lock);
623
    spinlock_unlock(&threads_lock);
622
    interrupts_restore(ipl);
624
    interrupts_restore(ipl);
623
}
625
}
624
 
626