aboutsummaryrefslogtreecommitdiff
path: root/arch/sh/kernel/kgdb.c
AgeCommit message (Collapse)Author
2014-02-13arch/sh/kernel/kgdb.c: add missing #include <linux/sched.h>Wanlong Gao
commit 53a52f17d96c8d47c79a7dafa81426317e89c7c1 upstream. arch/sh/kernel/kgdb.c: In function 'sleeping_thread_to_gdb_regs': arch/sh/kernel/kgdb.c:225:32: error: implicit declaration of function 'task_stack_page' [-Werror=implicit-function-declaration] arch/sh/kernel/kgdb.c:242:23: error: dereferencing pointer to incomplete type arch/sh/kernel/kgdb.c:243:22: error: dereferencing pointer to incomplete type arch/sh/kernel/kgdb.c: In function 'singlestep_trap_handler': arch/sh/kernel/kgdb.c:310:27: error: 'SIGTRAP' undeclared (first use in this function) arch/sh/kernel/kgdb.c:310:27: note: each undeclared identifier is reported only once for each function it appears in This was introduced by commit 16559ae48c76 ("kgdb: remove #include <linux/serial_8250.h> from kgdb.h"). [geert@linux-m68k.org: reworded and reformatted] Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@linux-m68k.org> Reported-by: Fengguang Wu <fengguang.wu@intel.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10sh: kgdb: Fix up NULL pointer deref by kgdb_nmicallback.Paul Mundt
kgdb_nmicallback expects valid register state, so just fetch the register state with get_irq_regs() as on other platforms. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2012-04-10sh: kgdb: Fill out sleeping_thread_to_gdb_regs() state.Paul Mundt
Presently we're using a pretty dumbed-down implementation that copies over register state visible from the thread info, leaving the bulk of the switch_to state uncopied. Given that we're also depending on register bank toggling for switch_to optimization we ought to also explicitly zero out the GP regs that reside in an alternate bank in order to prevent handing back garbage. There are a few extra registers that we have state for in switch_to, so copy those over while we're at it. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2012-04-10sh: kgdb: Individual register get/set support.Paul Mundt
This updates sh following the generic kgdb changes adding support for individual register get/set for kgdb/kdb use. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2012-04-10sh: kgdb: Fix up basic SMP support.Paul Mundt
kgdb needs a kgdb_roundup_cpus() definition in the architecture backend, so just copy over the MIPS version, which already does what we want. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2012-03-30sh: fix up fallout from system.h disintegration.Paul Mundt
Quite a bit of fallout all over the place, nothing terribly exciting. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-05-20kgdb,sh: update superh kgdb exception handlingJason Wessel
Implement kgdb_arch_pc() which adjusts the pc if it needs to be adjusted after a software breakpoint trap. Implement kgdb_arch_set_pc() which is a new required function in the kgdb debug core. When processing a single step return zero in the error exception field so that the debug core can distinguish between a single step trap and a breakpoint trap generically. Signed-off-by: Jason Wessel <jason.wessel@windriver.com> Acked-by: Paul Mundt <lethal@linux-sh.org>
2009-12-22sh: kgdb: Rework breakpoint handling on top of notifier chain.Paul Mundt
This kills off kgdb's breakpoint handler and ties in to the notifier chain instead. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2009-09-01sh: Kill off kgdb's magical NMI debouncing.Paul Mundt
The kgdb stub has traditionally tied in to the NMI slot, and manually handled debounce. Now that we have a generic way to do this instead, all of the stub-specific debounce silliness can be killed off. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2009-08-24sh: kgdb: do not reload VBR while handling debugger breackpointGiuseppe Cavallaro
Save the VBR allowing GDB to dump full registers set but do not reload it as soon as the kgdb_handle_exception is invoked. Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: Stuart Menefy <stuart.menefy@st.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2009-05-09sh: Rename opcode_t to insn_size_t.Paul Mundt
This is now clashing with a driver, so just rename it. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2008-12-22sh: Generic kgdb stub support.Paul Mundt
This migrates from the old bitrotted kgdb stub implementation and moves to the generic stub. In the process support for SH-2/SH-2A is also added, which the old stub never provided. Signed-off-by: Paul Mundt <lethal@linux-sh.org>