History log of /arch/mips/kernel/kgdb.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
eefc3f329d93404bfe1285d5b2f4380fede42e89 05-Aug-2010 Andrea Gelmini <andrea.gelmini@gelma.net> MIPS: Fix a typo.

"Userpace" -> "Userspace"

Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net>
Cc: Andrea Gelmini <andrea.gelmini@gelma.net>
Cc: Jason Wessel <jason.wessel@windriver.com>
Cc: Martin Hicks <mort@sgi.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/1536/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/kgdb.c
7aeb48b70b077375cdd2fe22f7a8b63ed6a98f25 05-Aug-2010 Jason Wessel <jason.wessel@windriver.com> kgdb,mips: remove unused kgdb_cpu_doing_single_step operations

The mips kgdb specific code does not support software or HW single
stepping so it should not implement

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Dongdong Deng <dongdong.deng@windriver.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
CC: linux-mips@linux-mips.org
/arch/mips/kernel/kgdb.c
0896a9becdea36b2da21709b5e73ba47ae6481ea 05-Aug-2010 Jason Wessel <jason.wessel@windriver.com> kgdb,mips: Individual register get/set for mips

Implement the ability to individually get and set registers for kdb
and kgdb for mips.

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
CC: linux-mips@linux-mips.org
/arch/mips/kernel/kgdb.c
5dd11d5d47d248850c58292513f0e164ba98b01e 21-May-2010 Jason Wessel <jason.wessel@windriver.com> mips,kgdb: kdb low level trap catch and stack trace

The only way the debugger can handle a trap in inside rcu_lock,
notify_die, or atomic_notifier_call_chain without a recursive fault is
to have a low level "first opportunity handler" do_trap_or_bp() handler.

Generally this will be something the vast majority of folks will not
need, but for those who need it, it is added as a kernel .config
option called KGDB_LOW_LEVEL_TRAP.

Also added was a die notification for oops such that kdb can catch an
oops for analysis.

There appeared to be no obvious way to pass the struct pt_regs from
the original exception back to the stack back tracer, so a special
case was added to show_stack() for when kdb is active because you
generally desire to generally look at the back trace of the original
exception.

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/kgdb.c
dcc7871128e99458ca86186b7bc8bf27ff0c47b5 21-May-2010 Jason Wessel <jason.wessel@windriver.com> kgdb: core changes to support kdb

These are the minimum changes to the kgdb core in order to enable an
API to connect a new front end (kdb) to the debug core.

This patch introduces the dbg_kdb_mode variable controls where the
user level I/O is routed. It will be routed to the gdbstub (kgdb) or
to the kdb front end which is a simple shell available over the kgdboc
connection.

You can switch back and forth between kdb or the gdb stub mode of
operation dynamically. From gdb stub mode you can blindly type
"$3#33", or from the kdb mode you can enter "kgdb" to switch to the
gdb stub.

The logic in the debug core depends on kdb to look for the typical gdb
connection sequences and return immediately with KGDB_PASS_EVENT if a
gdb serial command sequence is detected. That should allow a
reasonably seamless transition between kdb -> gdb without leaving the
kernel exception state. The two gdb serial queries that kdb is
responsible for detecting are the "?" and "qSupported" packets.

CC: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Acked-by: Martin Hicks <mort@sgi.com>
/arch/mips/kernel/kgdb.c
631330f5847b3f8a7ea67d689e9f7c56833ccaa6 19-Jun-2009 Ralf Baechle <ralf@linux-mips.org> MIPS: Build fix - include <linux/smp.h> into all smp_processor_id() users.

Some of the were relying into smp.h being dragged in by another header
which of course is fragile. <asm/cpu-info.h> uses smp_processor_id()
only in macros and including smp.h there leads to an include loop, so
don't change cpu-info.h.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/kgdb.c
d7161a65341556bacb5e6654e133803f46f51063 26-Sep-2008 Jason Wessel <jason.wessel@windriver.com> kgdb, x86, arm, mips, powerpc: ignore user space single stepping

On the x86 arch, user space single step exceptions should be ignored
if they occur in the kernel space, such as ptrace stepping through a
system call.

First check if it is kgdb that is executing a single step, then ensure
it is not an accidental traversal into the user space, while in kgdb,
any other time the TIF_SINGLESTEP is set, kgdb should ignore the
exception.

On x86, arm, mips and powerpc, the kgdb_contthread usage was
inconsistent with the way single stepping is implemented in the kgdb
core. The arch specific stub should always set the
kgdb_cpu_doing_single_step correctly if it is single stepping. This
allows kgdb to correctly process an instruction steps if ptrace
happens to be requesting an instruction step over a system call.

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
/arch/mips/kernel/kgdb.c
b895760dfb9b7ab921b066141d618bc6877f5d4b 11-Aug-2008 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [MIPS] kgdb: Do not call fixup_exception

kgdb_mips_notify is called on IBE/DBE/FPE/BP/TRAP/RI exception. None
of them need fixup. And doing fixup for a breakpoint exception will
confuse gdb.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/kgdb.c
9391d6bbedfd28c20531be75a3929c62bb43676e 06-Aug-2008 Ralf Baechle <ralf@linux-mips.org> [MIPS] kgdb: s/(void *)0)/NULL/

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/kgdb.c
e522b7ccd26a9774cac9379476ae3c6e005c88be 06-Aug-2008 Ralf Baechle <ralf@linux-mips.org> [MIPS] kgdb: smp_call_function's 3rd argument is a pointer.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/kgdb.c
8854700115ecf8aa6f087aa915b7b6cf18090d39 29-Jul-2008 Jason Wessel <jason.wessel@windriver.com> [MIPS] kgdb: add arch support for the kernel's kgdb core

The new kgdb architecture specific handler registers and unregisters
dynamically for exceptions depending on when you configure a kgdb I/O
driver.

Aside from initializing the exceptions earlier in the boot process,
kgdb should have no impact on a device when it is compiled in so long
as an I/O module is not configured for use.

There have been quite a number of contributors during the existence of
this patch (see arch/mips/kernel/kgdb.c). Most recently Jason
re-wrote the mips kgdb logic to use the die notification handlers.

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/kgdb.c