diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-10-12 22:16:58 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-10-12 22:16:58 -0400 |
commit | 6c536a17fa049d0fb690c1a947b97dbfd304a916 (patch) | |
tree | ed86fed39ac0952b2f21afee04d9d1494e9b904b /drivers/tty | |
parent | ba8a3d6c7c1956c6ff54a96e23007beccaa95640 (diff) | |
parent | f2f0945e356daef87cdb01c0302801fb11cf382a (diff) |
Merge tag 'for_linus-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb
Pull KGDB/KDB fixes and cleanups from Jason Wessel:
"Cleanups
- Clean up compile warnings in kgdboc.c and x86/kernel/kgdb.c
- Add module event hooks for simplified debugging with gdb
Fixes
- Fix kdb to stop paging with 'q' on bta and dmesg
- Fix for data that scrolls off the vga console due to line wrapping
when using the kdb pager
New
- The debug core registers for kernel module events which allows a
kernel aware gdb to automatically load symbols and break on entry
to a kernel module
- Allow kgdboc=kdb to setup kdb on the vga console"
* tag 'for_linus-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/kgdb:
tty/console: fix warnings in drivers/tty/serial/kgdboc.c
kdb,vt_console: Fix missed data due to pager overruns
kdb: Fix dmesg/bta scroll to quit with 'q'
kgdboc: Accept either kbd or kdb to activate the vga + keyboard kdb shell
kgdb,x86: fix warning about unused variable
mips,kgdb: fix recursive page fault with CONFIG_KPROBES
kgdb: Add module event hooks
Diffstat (limited to 'drivers/tty')
-rw-r--r-- | drivers/tty/serial/kgdboc.c | 3 | ||||
-rw-r--r-- | drivers/tty/vt/vt.c | 13 |
2 files changed, 15 insertions, 1 deletions
diff --git a/drivers/tty/serial/kgdboc.c b/drivers/tty/serial/kgdboc.c index c0b334327d93..10020547c60b 100644 --- a/drivers/tty/serial/kgdboc.c +++ b/drivers/tty/serial/kgdboc.c | |||
@@ -97,7 +97,8 @@ static void kgdboc_restore_input(void) | |||
97 | 97 | ||
98 | static int kgdboc_register_kbd(char **cptr) | 98 | static int kgdboc_register_kbd(char **cptr) |
99 | { | 99 | { |
100 | if (strncmp(*cptr, "kbd", 3) == 0) { | 100 | if (strncmp(*cptr, "kbd", 3) == 0 || |
101 | strncmp(*cptr, "kdb", 3) == 0) { | ||
101 | if (kdb_poll_idx < KDB_POLL_FUNC_MAX) { | 102 | if (kdb_poll_idx < KDB_POLL_FUNC_MAX) { |
102 | kdb_poll_funcs[kdb_poll_idx] = kdb_get_kbd_char; | 103 | kdb_poll_funcs[kdb_poll_idx] = kdb_get_kbd_char; |
103 | kdb_poll_idx++; | 104 | kdb_poll_idx++; |
diff --git a/drivers/tty/vt/vt.c b/drivers/tty/vt/vt.c index 999ca63afdef..f87d7e8964bf 100644 --- a/drivers/tty/vt/vt.c +++ b/drivers/tty/vt/vt.c | |||
@@ -3442,6 +3442,19 @@ int con_debug_enter(struct vc_data *vc) | |||
3442 | kdb_set(2, setargs); | 3442 | kdb_set(2, setargs); |
3443 | } | 3443 | } |
3444 | } | 3444 | } |
3445 | if (vc->vc_cols < 999) { | ||
3446 | int colcount; | ||
3447 | char cols[4]; | ||
3448 | const char *setargs[3] = { | ||
3449 | "set", | ||
3450 | "COLUMNS", | ||
3451 | cols, | ||
3452 | }; | ||
3453 | if (kdbgetintenv(setargs[0], &colcount)) { | ||
3454 | snprintf(cols, 4, "%i", vc->vc_cols); | ||
3455 | kdb_set(2, setargs); | ||
3456 | } | ||
3457 | } | ||
3445 | #endif /* CONFIG_KGDB_KDB */ | 3458 | #endif /* CONFIG_KGDB_KDB */ |
3446 | return ret; | 3459 | return ret; |
3447 | } | 3460 | } |