aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/tty_ldisc.c
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2012-10-18 16:26:47 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-10-22 19:58:28 -0400
commitecbbfd44a08fa80e0d664814efd4c187721b85f6 (patch)
treef1c9aea12eb27323b9e7f4b8329e47dc3c30e63d /drivers/tty/tty_ldisc.c
parent967fab6916681e5ab131fdef1226327b02454f19 (diff)
TTY: move tty buffers to tty_port
So this is it. The big step why we did all the work over the past kernel releases. Now everything is prepared, so nothing protects us from doing that big step. | | \ \ nnnn/^l | | | | \ / / | | | '-,.__ => \/ ,-` => | '-,.__ | O __.´´) ( .` | O __.´´) ~~~ ~~ `` ~~~ ~~ The buffers are now in the tty_port structure and we can start teaching the buffer helpers (insert char/string, flip etc.) to use tty_port instead of tty_struct all around. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Acked-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/tty_ldisc.c')
-rw-r--r--drivers/tty/tty_ldisc.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/tty/tty_ldisc.c b/drivers/tty/tty_ldisc.c
index 47e3968df10b..f4e6754525dc 100644
--- a/drivers/tty/tty_ldisc.c
+++ b/drivers/tty/tty_ldisc.c
@@ -512,7 +512,7 @@ static void tty_ldisc_restore(struct tty_struct *tty, struct tty_ldisc *old)
512static int tty_ldisc_halt(struct tty_struct *tty) 512static int tty_ldisc_halt(struct tty_struct *tty)
513{ 513{
514 clear_bit(TTY_LDISC, &tty->flags); 514 clear_bit(TTY_LDISC, &tty->flags);
515 return cancel_work_sync(&tty->buf.work); 515 return cancel_work_sync(&tty->port->buf.work);
516} 516}
517 517
518/** 518/**
@@ -525,7 +525,7 @@ static void tty_ldisc_flush_works(struct tty_struct *tty)
525{ 525{
526 flush_work(&tty->hangup_work); 526 flush_work(&tty->hangup_work);
527 flush_work(&tty->SAK_work); 527 flush_work(&tty->SAK_work);
528 flush_work(&tty->buf.work); 528 flush_work(&tty->port->buf.work);
529} 529}
530 530
531/** 531/**
@@ -704,9 +704,9 @@ enable:
704 /* Restart the work queue in case no characters kick it off. Safe if 704 /* Restart the work queue in case no characters kick it off. Safe if
705 already running */ 705 already running */
706 if (work) 706 if (work)
707 schedule_work(&tty->buf.work); 707 schedule_work(&tty->port->buf.work);
708 if (o_work) 708 if (o_work)
709 schedule_work(&o_tty->buf.work); 709 schedule_work(&o_tty->port->buf.work);
710 mutex_unlock(&tty->ldisc_mutex); 710 mutex_unlock(&tty->ldisc_mutex);
711 tty_unlock(tty); 711 tty_unlock(tty);
712 return retval; 712 return retval;
@@ -817,7 +817,7 @@ void tty_ldisc_hangup(struct tty_struct *tty)
817 */ 817 */
818 clear_bit(TTY_LDISC, &tty->flags); 818 clear_bit(TTY_LDISC, &tty->flags);
819 tty_unlock(tty); 819 tty_unlock(tty);
820 cancel_work_sync(&tty->buf.work); 820 cancel_work_sync(&tty->port->buf.work);
821 mutex_unlock(&tty->ldisc_mutex); 821 mutex_unlock(&tty->ldisc_mutex);
822retry: 822retry:
823 tty_lock(tty); 823 tty_lock(tty);