Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 4131 → Rev 4132

/trunk/kernel/arch/mips32/src/exception.c
41,7 → 41,6
#include <arch.h>
#include <debug.h>
#include <proc/thread.h>
#include <symtab.h>
#include <print.h>
#include <interrupt.h>
#include <func.h>
48,6 → 47,10
#include <ddi/irq.h>
#include <arch/debugger.h>
 
#ifdef CONFIG_SYMTAB
#include <symtab.h>
#endif
 
static char * exctable[] = {
"Interrupt",
"TLB Modified",
76,6 → 79,7
char *pcsymbol = "";
char *rasymbol = "";
 
#ifdef CONFIG_SYMTAB
char *s = get_symtab_entry(istate->epc);
if (s)
pcsymbol = s;
82,6 → 86,7
s = get_symtab_entry(istate->ra);
if (s)
rasymbol = s;
#endif
printf("PC: %#x(%s) RA: %#x(%s), SP(%p)\n", istate->epc, pcsymbol, istate->ra, rasymbol, istate->sp);
}
/trunk/kernel/arch/mips32/src/debugger.c
37,7 → 37,6
#include <memstr.h>
#include <console/kconsole.h>
#include <console/cmd.h>
#include <symtab.h>
#include <print.h>
#include <panic.h>
#include <arch.h>
44,6 → 43,10
#include <arch/cp0.h>
#include <func.h>
 
#ifdef CONFIG_SYMTAB
#include <symtab.h>
#endif
 
bpinfo_t breakpoints[BKPOINTS_MAX];
SPINLOCK_INITIALIZE(bkpoint_lock);
 
259,7 → 262,11
for (i = 0; i < BKPOINTS_MAX; i++)
if (breakpoints[i].address) {
#ifdef CONFIG_SYMTAB
symbol = get_symtab_entry(breakpoints[i].address);
#else
symbol = "n/a";
#endif
printf("%-2u %-5d %#10zx %-6s %-7s %-8s %s\n", i,
breakpoints[i].counter, breakpoints[i].address,
348,9 → 355,14
if (cur->flags & BKPOINT_INPROG)
printf("Warning: breakpoint recursion\n");
if (!(cur->flags & BKPOINT_FUNCCALL))
if (!(cur->flags & BKPOINT_FUNCCALL)) {
#ifdef CONFIG_SYMTAB
printf("***Breakpoint %d: %p in %s.\n", i, fireaddr,
get_symtab_entry(istate->epc));
#else
printf("***Breakpoint %d: %p.\n", i, fireaddr);
#endif
}
 
/* Return first instruction back */
((uint32_t *)cur->address)[0] = cur->instruction;
363,8 → 375,12
}
cur->flags |= BKPOINT_INPROG;
} else {
printf("***Breakpoint %p in %s.\n", fireaddr,
#ifdef CONFIG_SYMTAB
printf("***Breakpoint %p in %s.\n", fireaddr,
get_symtab_entry(fireaddr));
#else
printf("***Breakpoint %p.\n", fireaddr);
#endif
/* Move on to next instruction */
istate->epc += 4;
}
/trunk/kernel/arch/mips32/src/mm/tlb.c
40,7 → 40,6
#include <arch/cp0.h>
#include <panic.h>
#include <arch.h>
#include <symtab.h>
#include <synch/mutex.h>
#include <print.h>
#include <debug.h>
47,6 → 46,10
#include <align.h>
#include <interrupt.h>
 
#ifdef CONFIG_SYMTAB
#include <symtab.h>
#endif
 
static void tlb_refill_fail(istate_t *);
static void tlb_invalid_fail(istate_t *);
static void tlb_modified_fail(istate_t *);
323,6 → 326,7
char *symbol = "";
char *sym2 = "";
 
#ifdef CONFIG_SYMTAB
char *s = get_symtab_entry(istate->epc);
if (s)
symbol = s;
329,6 → 333,7
s = get_symtab_entry(istate->ra);
if (s)
sym2 = s;
#endif
 
fault_if_from_uspace(istate, "TLB Refill Exception on %p.",
cp0_badvaddr_read());
341,9 → 346,12
{
char *symbol = "";
 
#ifdef CONFIG_SYMTAB
char *s = get_symtab_entry(istate->epc);
if (s)
symbol = s;
#endif
 
fault_if_from_uspace(istate, "TLB Invalid Exception on %p.",
cp0_badvaddr_read());
panic("%x: TLB Invalid Exception at %x(%s).", cp0_badvaddr_read(),
354,9 → 362,12
{
char *symbol = "";
 
#ifdef CONFIG_SYMTAB
char *s = get_symtab_entry(istate->epc);
if (s)
symbol = s;
#endif
 
fault_if_from_uspace(istate, "TLB Modified Exception on %p.",
cp0_badvaddr_read());
panic("%x: TLB Modified Exception at %x(%s).", cp0_badvaddr_read(),