Skip to content

Commit 2637d13

Browse files
committed
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: pxa27x_keypad - remove input_free_device() in pxa27x_keypad_remove() Input: mousedev - fix regression of inverting axes Input: uinput - add devname alias to allow module on-demand load Input: hil_kbd - fix compile error USB: drop tty argument from usb_serial_handle_sysrq_char() Input: sysrq - drop tty argument form handle_sysrq() Input: sysrq - drop tty argument from sysrq ops handlers
2 parents 494e2fb + 288933c commit 2637d13

31 files changed

Lines changed: 75 additions & 80 deletions

File tree

arch/arm/kernel/etm.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ static void etm_dump(void)
230230
etb_lock(t);
231231
}
232232

233-
static void sysrq_etm_dump(int key, struct tty_struct *tty)
233+
static void sysrq_etm_dump(int key)
234234
{
235235
dev_dbg(tracer.dev, "Dumping ETB buffer\n");
236236
etm_dump();

arch/ia64/hp/sim/simserial.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ static void receive_chars(struct tty_struct *tty)
149149
ch = ia64_ssc(0, 0, 0, 0,
150150
SSC_GETCHAR);
151151
while (!ch);
152-
handle_sysrq(ch, NULL);
152+
handle_sysrq(ch);
153153
}
154154
#endif
155155
seen_esc = 0;

arch/powerpc/xmon/xmon.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2880,15 +2880,14 @@ static void xmon_init(int enable)
28802880
}
28812881

28822882
#ifdef CONFIG_MAGIC_SYSRQ
2883-
static void sysrq_handle_xmon(int key, struct tty_struct *tty)
2883+
static void sysrq_handle_xmon(int key)
28842884
{
28852885
/* ensure xmon is enabled */
28862886
xmon_init(1);
28872887
debugger(get_irq_regs());
28882888
}
28892889

2890-
static struct sysrq_key_op sysrq_xmon_op =
2891-
{
2890+
static struct sysrq_key_op sysrq_xmon_op = {
28922891
.handler = sysrq_handle_xmon,
28932892
.help_msg = "Xmon",
28942893
.action_msg = "Entering xmon",

arch/sparc/kernel/process_64.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ void arch_trigger_all_cpu_backtrace(void)
303303

304304
#ifdef CONFIG_MAGIC_SYSRQ
305305

306-
static void sysrq_handle_globreg(int key, struct tty_struct *tty)
306+
static void sysrq_handle_globreg(int key)
307307
{
308308
arch_trigger_all_cpu_backtrace();
309309
}

arch/um/drivers/mconsole_kern.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -690,7 +690,7 @@ static void with_console(struct mc_request *req, void (*proc)(void *),
690690
static void sysrq_proc(void *arg)
691691
{
692692
char *op = arg;
693-
handle_sysrq(*op, NULL);
693+
handle_sysrq(*op);
694694
}
695695

696696
void mconsole_sysrq(struct mc_request *req)

drivers/char/hangcheck-timer.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ static void hangcheck_fire(unsigned long data)
159159
if (hangcheck_dump_tasks) {
160160
printk(KERN_CRIT "Hangcheck: Task state:\n");
161161
#ifdef CONFIG_MAGIC_SYSRQ
162-
handle_sysrq('t', NULL);
162+
handle_sysrq('t');
163163
#endif /* CONFIG_MAGIC_SYSRQ */
164164
}
165165
if (hangcheck_reboot) {

drivers/char/hvc_console.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -651,7 +651,7 @@ int hvc_poll(struct hvc_struct *hp)
651651
if (sysrq_pressed)
652652
continue;
653653
} else if (sysrq_pressed) {
654-
handle_sysrq(buf[i], tty);
654+
handle_sysrq(buf[i]);
655655
sysrq_pressed = 0;
656656
continue;
657657
}

drivers/char/hvsi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ static void hvsi_insert_chars(struct hvsi_struct *hp, const char *buf, int len)
403403
hp->sysrq = 1;
404404
continue;
405405
} else if (hp->sysrq) {
406-
handle_sysrq(c, hp->tty);
406+
handle_sysrq(c);
407407
hp->sysrq = 0;
408408
continue;
409409
}

drivers/char/sysrq.c

Lines changed: 26 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
#include <linux/interrupt.h>
1919
#include <linux/mm.h>
2020
#include <linux/fs.h>
21-
#include <linux/tty.h>
2221
#include <linux/mount.h>
2322
#include <linux/kdev_t.h>
2423
#include <linux/major.h>
@@ -76,7 +75,7 @@ static int __init sysrq_always_enabled_setup(char *str)
7675
__setup("sysrq_always_enabled", sysrq_always_enabled_setup);
7776

7877

79-
static void sysrq_handle_loglevel(int key, struct tty_struct *tty)
78+
static void sysrq_handle_loglevel(int key)
8079
{
8180
int i;
8281

@@ -93,7 +92,7 @@ static struct sysrq_key_op sysrq_loglevel_op = {
9392
};
9493

9594
#ifdef CONFIG_VT
96-
static void sysrq_handle_SAK(int key, struct tty_struct *tty)
95+
static void sysrq_handle_SAK(int key)
9796
{
9897
struct work_struct *SAK_work = &vc_cons[fg_console].SAK_work;
9998
schedule_work(SAK_work);
@@ -109,7 +108,7 @@ static struct sysrq_key_op sysrq_SAK_op = {
109108
#endif
110109

111110
#ifdef CONFIG_VT
112-
static void sysrq_handle_unraw(int key, struct tty_struct *tty)
111+
static void sysrq_handle_unraw(int key)
113112
{
114113
struct kbd_struct *kbd = &kbd_table[fg_console];
115114

@@ -126,7 +125,7 @@ static struct sysrq_key_op sysrq_unraw_op = {
126125
#define sysrq_unraw_op (*(struct sysrq_key_op *)NULL)
127126
#endif /* CONFIG_VT */
128127

129-
static void sysrq_handle_crash(int key, struct tty_struct *tty)
128+
static void sysrq_handle_crash(int key)
130129
{
131130
char *killer = NULL;
132131

@@ -141,7 +140,7 @@ static struct sysrq_key_op sysrq_crash_op = {
141140
.enable_mask = SYSRQ_ENABLE_DUMP,
142141
};
143142

144-
static void sysrq_handle_reboot(int key, struct tty_struct *tty)
143+
static void sysrq_handle_reboot(int key)
145144
{
146145
lockdep_off();
147146
local_irq_enable();
@@ -154,7 +153,7 @@ static struct sysrq_key_op sysrq_reboot_op = {
154153
.enable_mask = SYSRQ_ENABLE_BOOT,
155154
};
156155

157-
static void sysrq_handle_sync(int key, struct tty_struct *tty)
156+
static void sysrq_handle_sync(int key)
158157
{
159158
emergency_sync();
160159
}
@@ -165,7 +164,7 @@ static struct sysrq_key_op sysrq_sync_op = {
165164
.enable_mask = SYSRQ_ENABLE_SYNC,
166165
};
167166

168-
static void sysrq_handle_show_timers(int key, struct tty_struct *tty)
167+
static void sysrq_handle_show_timers(int key)
169168
{
170169
sysrq_timer_list_show();
171170
}
@@ -176,7 +175,7 @@ static struct sysrq_key_op sysrq_show_timers_op = {
176175
.action_msg = "Show clockevent devices & pending hrtimers (no others)",
177176
};
178177

179-
static void sysrq_handle_mountro(int key, struct tty_struct *tty)
178+
static void sysrq_handle_mountro(int key)
180179
{
181180
emergency_remount();
182181
}
@@ -188,7 +187,7 @@ static struct sysrq_key_op sysrq_mountro_op = {
188187
};
189188

190189
#ifdef CONFIG_LOCKDEP
191-
static void sysrq_handle_showlocks(int key, struct tty_struct *tty)
190+
static void sysrq_handle_showlocks(int key)
192191
{
193192
debug_show_all_locks();
194193
}
@@ -226,7 +225,7 @@ static void sysrq_showregs_othercpus(struct work_struct *dummy)
226225

227226
static DECLARE_WORK(sysrq_showallcpus, sysrq_showregs_othercpus);
228227

229-
static void sysrq_handle_showallcpus(int key, struct tty_struct *tty)
228+
static void sysrq_handle_showallcpus(int key)
230229
{
231230
/*
232231
* Fall back to the workqueue based printing if the
@@ -252,7 +251,7 @@ static struct sysrq_key_op sysrq_showallcpus_op = {
252251
};
253252
#endif
254253

255-
static void sysrq_handle_showregs(int key, struct tty_struct *tty)
254+
static void sysrq_handle_showregs(int key)
256255
{
257256
struct pt_regs *regs = get_irq_regs();
258257
if (regs)
@@ -266,7 +265,7 @@ static struct sysrq_key_op sysrq_showregs_op = {
266265
.enable_mask = SYSRQ_ENABLE_DUMP,
267266
};
268267

269-
static void sysrq_handle_showstate(int key, struct tty_struct *tty)
268+
static void sysrq_handle_showstate(int key)
270269
{
271270
show_state();
272271
}
@@ -277,7 +276,7 @@ static struct sysrq_key_op sysrq_showstate_op = {
277276
.enable_mask = SYSRQ_ENABLE_DUMP,
278277
};
279278

280-
static void sysrq_handle_showstate_blocked(int key, struct tty_struct *tty)
279+
static void sysrq_handle_showstate_blocked(int key)
281280
{
282281
show_state_filter(TASK_UNINTERRUPTIBLE);
283282
}
@@ -291,7 +290,7 @@ static struct sysrq_key_op sysrq_showstate_blocked_op = {
291290
#ifdef CONFIG_TRACING
292291
#include <linux/ftrace.h>
293292

294-
static void sysrq_ftrace_dump(int key, struct tty_struct *tty)
293+
static void sysrq_ftrace_dump(int key)
295294
{
296295
ftrace_dump(DUMP_ALL);
297296
}
@@ -305,7 +304,7 @@ static struct sysrq_key_op sysrq_ftrace_dump_op = {
305304
#define sysrq_ftrace_dump_op (*(struct sysrq_key_op *)NULL)
306305
#endif
307306

308-
static void sysrq_handle_showmem(int key, struct tty_struct *tty)
307+
static void sysrq_handle_showmem(int key)
309308
{
310309
show_mem();
311310
}
@@ -330,7 +329,7 @@ static void send_sig_all(int sig)
330329
}
331330
}
332331

333-
static void sysrq_handle_term(int key, struct tty_struct *tty)
332+
static void sysrq_handle_term(int key)
334333
{
335334
send_sig_all(SIGTERM);
336335
console_loglevel = 8;
@@ -349,7 +348,7 @@ static void moom_callback(struct work_struct *ignored)
349348

350349
static DECLARE_WORK(moom_work, moom_callback);
351350

352-
static void sysrq_handle_moom(int key, struct tty_struct *tty)
351+
static void sysrq_handle_moom(int key)
353352
{
354353
schedule_work(&moom_work);
355354
}
@@ -361,7 +360,7 @@ static struct sysrq_key_op sysrq_moom_op = {
361360
};
362361

363362
#ifdef CONFIG_BLOCK
364-
static void sysrq_handle_thaw(int key, struct tty_struct *tty)
363+
static void sysrq_handle_thaw(int key)
365364
{
366365
emergency_thaw_all();
367366
}
@@ -373,7 +372,7 @@ static struct sysrq_key_op sysrq_thaw_op = {
373372
};
374373
#endif
375374

376-
static void sysrq_handle_kill(int key, struct tty_struct *tty)
375+
static void sysrq_handle_kill(int key)
377376
{
378377
send_sig_all(SIGKILL);
379378
console_loglevel = 8;
@@ -385,7 +384,7 @@ static struct sysrq_key_op sysrq_kill_op = {
385384
.enable_mask = SYSRQ_ENABLE_SIGNAL,
386385
};
387386

388-
static void sysrq_handle_unrt(int key, struct tty_struct *tty)
387+
static void sysrq_handle_unrt(int key)
389388
{
390389
normalize_rt_tasks();
391390
}
@@ -493,7 +492,7 @@ static void __sysrq_put_key_op(int key, struct sysrq_key_op *op_p)
493492
sysrq_key_table[i] = op_p;
494493
}
495494

496-
void __handle_sysrq(int key, struct tty_struct *tty, int check_mask)
495+
void __handle_sysrq(int key, bool check_mask)
497496
{
498497
struct sysrq_key_op *op_p;
499498
int orig_log_level;
@@ -520,7 +519,7 @@ void __handle_sysrq(int key, struct tty_struct *tty, int check_mask)
520519
if (!check_mask || sysrq_on_mask(op_p->enable_mask)) {
521520
printk("%s\n", op_p->action_msg);
522521
console_loglevel = orig_log_level;
523-
op_p->handler(key, tty);
522+
op_p->handler(key);
524523
} else {
525524
printk("This sysrq operation is disabled.\n");
526525
}
@@ -545,10 +544,10 @@ void __handle_sysrq(int key, struct tty_struct *tty, int check_mask)
545544
spin_unlock_irqrestore(&sysrq_key_table_lock, flags);
546545
}
547546

548-
void handle_sysrq(int key, struct tty_struct *tty)
547+
void handle_sysrq(int key)
549548
{
550549
if (sysrq_on())
551-
__handle_sysrq(key, tty, 1);
550+
__handle_sysrq(key, true);
552551
}
553552
EXPORT_SYMBOL(handle_sysrq);
554553

@@ -597,7 +596,7 @@ static bool sysrq_filter(struct input_handle *handle, unsigned int type,
597596

598597
default:
599598
if (sysrq_down && value && value != 2)
600-
__handle_sysrq(sysrq_xlate[code], NULL, 1);
599+
__handle_sysrq(sysrq_xlate[code], true);
601600
break;
602601
}
603602

@@ -765,7 +764,7 @@ static ssize_t write_sysrq_trigger(struct file *file, const char __user *buf,
765764

766765
if (get_user(c, buf))
767766
return -EFAULT;
768-
__handle_sysrq(c, NULL, 0);
767+
__handle_sysrq(c, false);
769768
}
770769

771770
return count;

drivers/gpu/drm/drm_fb_helper.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ static void drm_fb_helper_restore_work_fn(struct work_struct *ignored)
370370
}
371371
static DECLARE_WORK(drm_fb_helper_restore_work, drm_fb_helper_restore_work_fn);
372372

373-
static void drm_fb_helper_sysrq(int dummy1, struct tty_struct *dummy3)
373+
static void drm_fb_helper_sysrq(int dummy1)
374374
{
375375
schedule_work(&drm_fb_helper_restore_work);
376376
}

0 commit comments

Comments
 (0)