aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/sysrq.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2010-08-18 00:15:47 -0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2010-08-21 03:34:45 -0400
commitf335397d177c906256ee1bba28e8c49e8ec63817 (patch)
treeb6911d0b40940cbec9083769856e7744d5461e22 /drivers/char/sysrq.c
parent1495cc9df4e81f5a8fa9b0b8f1034b14d24b7d8c (diff)
Input: sysrq - drop tty argument form handle_sysrq()
Sysrq operations do not accept tty argument anymore so no need to pass it to us. [Stephen Rothwell <sfr@canb.auug.org.au>: fix build breakage in drm code caused by sysrq using bool but not including linux/types.h] [Sachin Sant <sachinp@in.ibm.com>: fix build breakage in s390 keyboadr driver] Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk> Acked-by: Jason Wessel <jason.wessel@windriver.com> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/char/sysrq.c')
-rw-r--r--drivers/char/sysrq.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/char/sysrq.c b/drivers/char/sysrq.c
index a892a3c249dd..ef31bb81e843 100644
--- a/drivers/char/sysrq.c
+++ b/drivers/char/sysrq.c
@@ -18,7 +18,6 @@
18#include <linux/interrupt.h> 18#include <linux/interrupt.h>
19#include <linux/mm.h> 19#include <linux/mm.h>
20#include <linux/fs.h> 20#include <linux/fs.h>
21#include <linux/tty.h>
22#include <linux/mount.h> 21#include <linux/mount.h>
23#include <linux/kdev_t.h> 22#include <linux/kdev_t.h>
24#include <linux/major.h> 23#include <linux/major.h>
@@ -493,7 +492,7 @@ static void __sysrq_put_key_op(int key, struct sysrq_key_op *op_p)
493 sysrq_key_table[i] = op_p; 492 sysrq_key_table[i] = op_p;
494} 493}
495 494
496void __handle_sysrq(int key, struct tty_struct *tty, int check_mask) 495void __handle_sysrq(int key, bool check_mask)
497{ 496{
498 struct sysrq_key_op *op_p; 497 struct sysrq_key_op *op_p;
499 int orig_log_level; 498 int orig_log_level;
@@ -545,10 +544,10 @@ void __handle_sysrq(int key, struct tty_struct *tty, int check_mask)
545 spin_unlock_irqrestore(&sysrq_key_table_lock, flags); 544 spin_unlock_irqrestore(&sysrq_key_table_lock, flags);
546} 545}
547 546
548void handle_sysrq(int key, struct tty_struct *tty) 547void handle_sysrq(int key)
549{ 548{
550 if (sysrq_on()) 549 if (sysrq_on())
551 __handle_sysrq(key, tty, 1); 550 __handle_sysrq(key, true);
552} 551}
553EXPORT_SYMBOL(handle_sysrq); 552EXPORT_SYMBOL(handle_sysrq);
554 553
@@ -597,7 +596,7 @@ static bool sysrq_filter(struct input_handle *handle, unsigned int type,
597 596
598 default: 597 default:
599 if (sysrq_down && value && value != 2) 598 if (sysrq_down && value && value != 2)
600 __handle_sysrq(sysrq_xlate[code], NULL, 1); 599 __handle_sysrq(sysrq_xlate[code], true);
601 break; 600 break;
602 } 601 }
603 602
@@ -765,7 +764,7 @@ static ssize_t write_sysrq_trigger(struct file *file, const char __user *buf,
765 764
766 if (get_user(c, buf)) 765 if (get_user(c, buf))
767 return -EFAULT; 766 return -EFAULT;
768 __handle_sysrq(c, NULL, 0); 767 __handle_sysrq(c, false);
769 } 768 }
770 769
771 return count; 770 return count;