aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/hvc_console.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/char/hvc_console.c')
-rw-r--r--drivers/char/hvc_console.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/char/hvc_console.c b/drivers/char/hvc_console.c
index 5b819b12675a..5a8a4c28c867 100644
--- a/drivers/char/hvc_console.c
+++ b/drivers/char/hvc_console.c
@@ -529,7 +529,7 @@ static void hvc_set_winsz(struct work_struct *work)
529 tty = tty_kref_get(hp->tty); 529 tty = tty_kref_get(hp->tty);
530 spin_unlock_irqrestore(&hp->lock, hvc_flags); 530 spin_unlock_irqrestore(&hp->lock, hvc_flags);
531 531
532 tty_do_resize(tty, tty, &ws); 532 tty_do_resize(tty, &ws);
533 tty_kref_put(tty); 533 tty_kref_put(tty);
534} 534}
535 535
@@ -642,8 +642,11 @@ int hvc_poll(struct hvc_struct *hp)
642 /* Handle the SysRq Hack */ 642 /* Handle the SysRq Hack */
643 /* XXX should support a sequence */ 643 /* XXX should support a sequence */
644 if (buf[i] == '\x0f') { /* ^O */ 644 if (buf[i] == '\x0f') { /* ^O */
645 sysrq_pressed = 1; 645 /* if ^O is pressed again, reset
646 continue; 646 * sysrq_pressed and flip ^O char */
647 sysrq_pressed = !sysrq_pressed;
648 if (sysrq_pressed)
649 continue;
647 } else if (sysrq_pressed) { 650 } else if (sysrq_pressed) {
648 handle_sysrq(buf[i], tty); 651 handle_sysrq(buf[i], tty);
649 sysrq_pressed = 0; 652 sysrq_pressed = 0;
@@ -689,11 +692,10 @@ EXPORT_SYMBOL_GPL(hvc_poll);
689 */ 692 */
690void hvc_resize(struct hvc_struct *hp, struct winsize ws) 693void hvc_resize(struct hvc_struct *hp, struct winsize ws)
691{ 694{
692 if ((hp->ws.ws_row != ws.ws_row) || (hp->ws.ws_col != ws.ws_col)) { 695 hp->ws = ws;
693 hp->ws = ws; 696 schedule_work(&hp->tty_resize);
694 schedule_work(&hp->tty_resize);
695 }
696} 697}
698EXPORT_SYMBOL_GPL(hvc_resize);
697 699
698/* 700/*
699 * This kthread is either polling or interrupt driven. This is determined by 701 * This kthread is either polling or interrupt driven. This is determined by