aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2007-02-16 04:28:16 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-16 11:13:59 -0500
commit88ad0bf6890505cbd9ca1dbb79944a27b5c8697d (patch)
treee78711c47de9da92c8e4db8029f43542cecdf268 /drivers
parent289f480af87e45f7a6de6ba9b4c061c2e259fe98 (diff)
[PATCH] Add SysRq-Q to print timer_list debug info
Add SysRq-Q to print pending timers and other timer info. Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: john stultz <johnstul@us.ibm.com> Cc: Roman Zippel <zippel@linux-m68k.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/char/sysrq.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/drivers/char/sysrq.c b/drivers/char/sysrq.c
index be73c80d699d..1d8c4ae61551 100644
--- a/drivers/char/sysrq.c
+++ b/drivers/char/sysrq.c
@@ -36,6 +36,7 @@
36#include <linux/workqueue.h> 36#include <linux/workqueue.h>
37#include <linux/kexec.h> 37#include <linux/kexec.h>
38#include <linux/irq.h> 38#include <linux/irq.h>
39#include <linux/hrtimer.h>
39 40
40#include <asm/ptrace.h> 41#include <asm/ptrace.h>
41#include <asm/irq_regs.h> 42#include <asm/irq_regs.h>
@@ -158,6 +159,17 @@ static struct sysrq_key_op sysrq_sync_op = {
158 .enable_mask = SYSRQ_ENABLE_SYNC, 159 .enable_mask = SYSRQ_ENABLE_SYNC,
159}; 160};
160 161
162static void sysrq_handle_show_timers(int key, struct tty_struct *tty)
163{
164 sysrq_timer_list_show();
165}
166
167static struct sysrq_key_op sysrq_show_timers_op = {
168 .handler = sysrq_handle_show_timers,
169 .help_msg = "show-all-timers(Q)",
170 .action_msg = "Show Pending Timers",
171};
172
161static void sysrq_handle_mountro(int key, struct tty_struct *tty) 173static void sysrq_handle_mountro(int key, struct tty_struct *tty)
162{ 174{
163 emergency_remount(); 175 emergency_remount();
@@ -335,7 +347,7 @@ static struct sysrq_key_op *sysrq_key_table[36] = {
335 /* o: This will often be registered as 'Off' at init time */ 347 /* o: This will often be registered as 'Off' at init time */
336 NULL, /* o */ 348 NULL, /* o */
337 &sysrq_showregs_op, /* p */ 349 &sysrq_showregs_op, /* p */
338 NULL, /* q */ 350 &sysrq_show_timers_op, /* q */
339 &sysrq_unraw_op, /* r */ 351 &sysrq_unraw_op, /* r */
340 &sysrq_sync_op, /* s */ 352 &sysrq_sync_op, /* s */
341 &sysrq_showstate_op, /* t */ 353 &sysrq_showstate_op, /* t */