nios2: add kgdb support

Signed-off-by: Ley Foon Tan <lftan@altera.com>
This commit is contained in:
Ley Foon Tan
2015-02-16 19:26:43 +08:00
parent 08c283cc03
commit d16d2be111
5 changed files with 277 additions and 1 deletions

View File

@@ -121,7 +121,11 @@ trap_table:
.word instruction_trap /* 27 */
.word instruction_trap /* 28 */
.word instruction_trap /* 29 */
.word instruction_trap /* 30 */
#ifdef CONFIG_KGDB
.word handle_kgdb_breakpoint /* 30 KGDB breakpoint */
#else
.word instruction_trap /* 30 */
#endif
.word handle_breakpoint /* 31 */
.text
@@ -445,6 +449,12 @@ handle_diverror:
call handle_diverror_c
br ret_from_exception
#ifdef CONFIG_KGDB
handle_kgdb_breakpoint:
call kgdb_breakpoint_c
br ret_from_exception
#endif
/*
* Beware - when entering resume, prev (the current task) is
* in r4, next (the new task) is in r5, don't change these