CHROMIUM: sysrq: Added Chrome OS specific 'x' key
authorSameer Nanda <snanda@chromium.org>
Mon, 6 Aug 2012 16:16:21 +0000 (09:16 -0700)
committerGerrit <chrome-bot@google.com>
Mon, 6 Aug 2012 23:31:56 +0000 (16:31 -0700)
commit937c997ef624dc656a64c97a47ef57b4a189bbc6
treee7a3653c57d38f48365cd0876eab0924cfab0198
parent3b7548a6e7b688a895294cd0aa5978b52aa8f57a
CHROMIUM: sysrq: Added Chrome OS specific 'x' key

On Chrome OS systems the magic sysrq x key will cause the following to
happen:
- show processes in blocked state
- emergency file sync
- crash the system

This key combination can be used in the field by users to cause the
system to crash so that crash dumps can be collected to help debug UI
freeze issues.

BUG=chromium-os:33249
TEST=First "echo 0x1000 > /proc/sys/kernel/sysrq", then do the two tests
below:
1. Alt-F10-x should cause the system to crash. Looks for kcrash logs
under /var/spool/crash when the system reboots.
2. All other magic sysrq operation aside from alt-F10-x should be
ineffective.

Change-Id: I62d0a7f0028c072928be0125da4e069bafa5d88c
Signed-off-by: Sameer Nanda <snanda@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/29316
Reviewed-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Olof Johansson <olofj@chromium.org>
drivers/tty/sysrq.c
include/linux/sysrq.h