Changeset b2fa1204 in mainline for kernel/arch/mips32/src/exception.c


Ignore:
Timestamp:
2014-01-05T21:12:26Z (10 years ago)
Author:
Martin Sucha <sucha14@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ca05e9b
Parents:
bd6ff94
Message:

Cherrypick usage of kernel logger

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/mips32/src/exception.c

    rbd6ff94 rb2fa1204  
    4848#include <arch/debugger.h>
    4949#include <symtab.h>
     50#include <log.h>
    5051
    5152static const char *exctable[] = {
     
    7475void istate_decode(istate_t *istate)
    7576{
    76         printf("epc=%#010" PRIx32 "\tsta=%#010" PRIx32 "\t"
     77        log_printf("epc=%#010" PRIx32 "\tsta=%#010" PRIx32 "\t"
    7778            "lo =%#010" PRIx32 "\thi =%#010" PRIx32 "\n",
    7879            istate->epc, istate->status, istate->lo, istate->hi);
    7980       
    80         printf("a0 =%#010" PRIx32 "\ta1 =%#010" PRIx32 "\t"
     81        log_printf("a0 =%#010" PRIx32 "\ta1 =%#010" PRIx32 "\t"
    8182            "a2 =%#010" PRIx32 "\ta3 =%#010" PRIx32 "\n",
    8283            istate->a0, istate->a1, istate->a2, istate->a3);
    8384       
    84         printf("t0 =%#010" PRIx32 "\tt1 =%#010" PRIx32 "\t"
     85        log_printf("t0 =%#010" PRIx32 "\tt1 =%#010" PRIx32 "\t"
    8586            "t2 =%#010" PRIx32 "\tt3 =%#010" PRIx32 "\n",
    8687            istate->t0, istate->t1, istate->t2, istate->t3);
    8788       
    88         printf("t4 =%#010" PRIx32 "\tt5 =%#010" PRIx32 "\t"
     89        log_printf("t4 =%#010" PRIx32 "\tt5 =%#010" PRIx32 "\t"
    8990            "t6 =%#010" PRIx32 "\tt7 =%#010" PRIx32 "\n",
    9091            istate->t4, istate->t5, istate->t6, istate->t7);
    9192       
    92         printf("t8 =%#010" PRIx32 "\tt9 =%#010" PRIx32 "\t"
     93        log_printf("t8 =%#010" PRIx32 "\tt9 =%#010" PRIx32 "\t"
    9394            "v0 =%#010" PRIx32 "\tv1 =%#010" PRIx32 "\n",
    9495            istate->t8, istate->t9, istate->v0, istate->v1);
    9596       
    96         printf("s0 =%#010" PRIx32 "\ts1 =%#010" PRIx32 "\t"
     97        log_printf("s0 =%#010" PRIx32 "\ts1 =%#010" PRIx32 "\t"
    9798            "s2 =%#010" PRIx32 "\ts3 =%#010" PRIx32 "\n",
    9899            istate->s0, istate->s1, istate->s2, istate->s3);
    99100       
    100         printf("s4 =%#010" PRIx32 "\ts5 =%#010" PRIx32 "\t"
     101        log_printf("s4 =%#010" PRIx32 "\ts5 =%#010" PRIx32 "\t"
    101102            "s6 =%#010" PRIx32 "\ts7 =%#010" PRIx32 "\n",
    102103            istate->s4, istate->s5, istate->s6, istate->s7);
    103104       
    104         printf("s8 =%#010" PRIx32 "\tat =%#010" PRIx32 "\t"
     105        log_printf("s8 =%#010" PRIx32 "\tat =%#010" PRIx32 "\t"
    105106            "kt0=%#010" PRIx32 "\tkt1=%#010" PRIx32 "\n",
    106107            istate->s8, istate->at, istate->kt0, istate->kt1);
    107108       
    108         printf("sp =%#010" PRIx32 "\tra =%#010" PRIx32 "\t"
     109        log_printf("sp =%#010" PRIx32 "\tra =%#010" PRIx32 "\t"
    109110            "gp =%#010" PRIx32 "\n",
    110111            istate->sp, istate->ra, istate->gp);
     
    194195                                 */
    195196#ifdef CONFIG_DEBUG
    196                                 printf("cpu%u: spurious interrupt (inum=%u)\n",
     197                                log(LF_ARCH, LVL_DEBUG,
     198                                    "cpu%u: spurious interrupt (inum=%u)",
    197199                                    CPU->id, i);
    198200#endif
Note: See TracChangeset for help on using the changeset viewer.