- refactored debugger

- jump to exc-handler instead of call

git-svn-id: http://moon:8086/svn/mips@115 a8ebac50-d88d-4704-bea3-6648445a41b3
This commit is contained in:
2017-01-21 17:46:50 +00:00
parent d1f91b7282
commit c6962aef49
5 changed files with 12 additions and 7 deletions
+8 -2
View File
@@ -13,11 +13,17 @@
extern uart_if_t uart_if[];
extern void handle_exception (unsigned long *registers);
extern int gdb_stub(struct xcptcontext * xcp) __attribute__ ((section (".gdb"))) __attribute__ ((used));
int gdb_stub(struct xcptcontext * xcp)
extern int dbg_stub(struct xcptcontext * xcp) __attribute__ ((section (".dbg_stub"))) __attribute__ ((used));
int dbg_stub(struct xcptcontext * xcp)
{
#ifdef WITH_GDB_STUB
handle_exception((unsigned long *)xcp);
return 0;
#else
return dbg_handler(xcp);
#endif
}
void dbg_putchar(char c)