Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/proc/task.c

    r2f2beb4 r5d0500c  
    9090        TASK = NULL;
    9191        avltree_create(&tasks_tree);
    92         task_slab = slab_cache_create("task_t", sizeof(task_t), 0,
     92        task_slab = slab_cache_create("task_slab", sizeof(task_t), 0,
    9393            tsk_constructor, NULL, 0);
    9494}
     
    125125{
    126126        size_t tasks_left;
    127 
    128         if (ipc_phone_0) {
    129                 task_t *task_0 = ipc_phone_0->task;
    130                 ipc_phone_0 = NULL;
    131                 /*
    132                  * The first task is held by kinit(), we need to release it or
    133                  * it will never finish cleanup.
    134                  */
    135                 task_release(task_0);
    136         }
    137127       
    138128        /* Repeat until there are any tasks except TASK */
     
    166156       
    167157        list_initialize(&task->threads);
     158        list_initialize(&task->sync_boxes);
    168159       
    169160        ipc_answerbox_init(&task->answerbox, task);
     
    171162        size_t i;
    172163        for (i = 0; i < IPC_MAX_PHONES; i++)
    173                 ipc_phone_init(&task->phones[i], task);
    174 
    175         spinlock_initialize(&task->active_calls_lock, "active_calls_lock");
    176         list_initialize(&task->active_calls);
     164                ipc_phone_init(&task->phones[i]);
    177165       
    178166#ifdef CONFIG_UDEBUG
     
    206194        task->ucycles = 0;
    207195        task->kcycles = 0;
    208 
     196       
    209197        task->ipc_info.call_sent = 0;
    210198        task->ipc_info.call_received = 0;
     
    216204        event_task_init(task);
    217205       
    218         task->answerbox.active = true;
    219 
    220206#ifdef CONFIG_UDEBUG
    221207        /* Init debugging stuff */
     
    223209       
    224210        /* Init kbox stuff */
    225         task->kb.box.active = true;
    226211        task->kb.finished = false;
    227212#endif
     
    229214        if ((ipc_phone_0) &&
    230215            (container_check(ipc_phone_0->task->container, task->container)))
    231                 (void) ipc_phone_connect(&task->phones[0], ipc_phone_0);
     216                ipc_phone_connect(&task->phones[0], ipc_phone_0);
    232217       
    233218        btree_create(&task->futexes);
Note: See TracChangeset for help on using the changeset viewer.