Changeset 0108984a in mainline for kernel/generic/src/ipc/ipc_kbox.c


Ignore:
Timestamp:
2008-09-17T13:38:18Z (16 years ago)
Author:
Jiri Svoboda <jirik.svoboda@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
c9a29d6
Parents:
fb9b0b0
Message:

Use LOG() instead of printf() for debug messages.

File:
1 edited

Legend:

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

    rfb9b0b0 r0108984a  
    4040#include <arch.h>
    4141#include <errno.h>
    42 #include <print.h>
     42#include <debug.h>
    4343#include <udebug/udebug_ipc.h>
    4444#include <ipc/ipc_kbox.h>
     
    6666       
    6767        if (have_kb_thread) {
    68                 printf("join kb_thread..\n");
     68                LOG("join kb_thread..\n");
    6969                thread_join(TASK->kb_thread);
    7070                thread_detach(TASK->kb_thread);
    71                 printf("join done\n");
     71                LOG("join done\n");
    7272                TASK->kb_thread = NULL;
    7373        }
     
    8989
    9090        (void)arg;
    91         printf("kbox_thread_proc()\n");
     91        LOG("kbox_thread_proc()\n");
    9292        done = false;
    9393
    9494        while (!done) {
    95                 //printf("kbox: wait for call\n");
    9695                call = ipc_wait_for_call(&TASK->kernel_box, SYNCH_NO_TIMEOUT,
    9796                        SYNCH_FLAGS_NONE);
     
    105104
    106105                        if (method == IPC_M_PHONE_HUNGUP) {
    107                                 printf("kbox: handle hangup message\n");
     106                                LOG("kbox: handle hangup message\n");
    108107
    109108                                /* Was it our debugger, who hung up? */
    110109                                if (call->sender == TASK->udebug.debugger) {
    111110                                        /* Terminate debugging session (if any) */
    112                                         printf("kbox: terminate debug session\n");
     111                                        LOG("kbox: terminate debug session\n");
    113112                                        ipl = interrupts_disable();
    114113                                        spinlock_lock(&TASK->lock);
     
    117116                                        interrupts_restore(ipl);
    118117                                } else {
    119                                         printf("kbox: was not debugger\n");
     118                                        LOG("kbox: was not debugger\n");
    120119                                }
    121120
    122                                 printf("kbox: continue with hangup message\n");
     121                                LOG("kbox: continue with hangup message\n");
    123122                                IPC_SET_RETVAL(call->data, 0);
    124123                                ipc_answer(&TASK->kernel_box, call);
     
    131130                                        TASK->kb_thread = NULL;
    132131                                        done = true;
    133                                         printf("phone list is empty\n");
     132                                        LOG("phone list is empty\n");
    134133                                }
    135134                                spinlock_unlock(&TASK->answerbox.lock);
     
    140139        }
    141140
    142         printf("kbox: finished\n");
     141        LOG("kbox: finished\n");
    143142}
    144143
Note: See TracChangeset for help on using the changeset viewer.