summaryrefslogtreecommitdiffstats
path: root/tty/tiny_tty.c
diff options
context:
space:
mode:
authorJavier Martinez Canillas <javier@dowhile0.org>2013-04-26 22:56:05 +0200
committerJavier Martinez Canillas <javier@dowhile0.org>2013-04-27 01:48:13 +0200
commitd9c53b5a84cc98e901b5eb0bdd925edecbe334d7 (patch)
treea2a8a16316cc219a3864c95f94434316faea14a4 /tty/tiny_tty.c
parentfbb342780c8ce22579fedb4ef260d0ac3cd764d8 (diff)
downloadldd3-d9c53b5a84cc98e901b5eb0bdd925edecbe334d7.tar.gz
tty: pass tty_port to tty functions instead of tty_struct
commit 227434f8 ("TTY: switch tty_buffer_request_room to tty_port") started to convert all tty functions to receive a tty_port instead of a tt_struct. Update the drivers according this API change. Signed-off-by: Javier Martinez Canillas <javier@dowhile0.org>
Diffstat (limited to 'tty/tiny_tty.c')
-rw-r--r--tty/tiny_tty.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/tty/tiny_tty.c b/tty/tiny_tty.c
index 64a74c7..b63e443 100644
--- a/tty/tiny_tty.c
+++ b/tty/tiny_tty.c
@@ -65,6 +65,7 @@ static void tiny_timer(unsigned long timer_data)
{
struct tiny_serial *tiny = (struct tiny_serial *)timer_data;
struct tty_struct *tty;
+ struct tty_port *port;
int i;
char data[1] = {TINY_DATA_CHARACTER};
int data_size = 1;
@@ -73,15 +74,16 @@ static void tiny_timer(unsigned long timer_data)
return;
tty = tiny->tty;
+ port = tty->port;
/* send the data to the tty layer for users to read. This doesn't
* actually push the data through unless tty->low_latency is set */
for (i = 0; i < data_size; ++i) {
- if (!tty_buffer_request_room(tty, 1))
- tty_flip_buffer_push(tty);
- tty_insert_flip_char(tty, data[i], TTY_NORMAL);
+ if (!tty_buffer_request_room(port, 1))
+ tty_flip_buffer_push(port);
+ tty_insert_flip_char(port, data[i], TTY_NORMAL);
}
- tty_flip_buffer_push(tty);
+ tty_flip_buffer_push(port);
/* resubmit the timer again */
tiny->timer->expires = jiffies + DELAY_TIME;