Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/ipc/kbox.c

    r716185d r1066041  
    4444#include <ipc/kbox.h>
    4545#include <print.h>
     46#include <proc/thread.h>
    4647
    4748void ipc_kbox_cleanup(void)
    4849{
    49         /*
    50          * Not really needed, just to be consistent with the meaning of
    51          * answerbox_t.active.
    52          */
    53         irq_spinlock_lock(&TASK->kb.box.lock, true);
    54         TASK->kb.box.active = false;
    55         irq_spinlock_unlock(&TASK->kb.box.lock, true);
    56 
    5750        /*
    5851         * Only hold kb.cleanup_lock while setting kb.finished -
     
    9689       
    9790        /* Answer all messages in 'calls' and 'dispatched_calls' queues. */
    98         ipc_cleanup_call_list(&TASK->kb.box, &TASK->kb.box.calls);
    99         ipc_cleanup_call_list(&TASK->kb.box, &TASK->kb.box.dispatched_calls);
     91        irq_spinlock_lock(&TASK->kb.box.lock, true);
     92        ipc_cleanup_call_list(&TASK->kb.box.dispatched_calls);
     93        ipc_cleanup_call_list(&TASK->kb.box.calls);
     94        irq_spinlock_unlock(&TASK->kb.box.lock, true);
    10095}
    10196
     
    168163        while (!done) {
    169164                call_t *call = ipc_wait_for_call(&TASK->kb.box, SYNCH_NO_TIMEOUT,
    170                     SYNCH_FLAGS_NONE);
     165                        SYNCH_FLAGS_NONE);
    171166               
    172167                if (call == NULL)
     
    242237       
    243238        /* Connect the newly allocated phone to the kbox */
    244         (void) ipc_phone_connect(&TASK->phones[newphid], &task->kb.box);
     239        ipc_phone_connect(&TASK->phones[newphid], &task->kb.box);
    245240       
    246241        if (task->kb.thread != NULL) {
Note: See TracChangeset for help on using the changeset viewer.