From 6eff78fd4a5a8b2abb42db3ec8d861decbc00383 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Mon, 30 Nov 2009 13:18:08 +0000 Subject: [PATCH] --- yaml --- r: 175357 b: refs/heads/master c: f9b412a8c9adb17d50922f91962e8b1e48789430 h: refs/heads/master i: 175355: 2a6aa7764d38148e12999613513f150d23bf1916 v: v3 --- [refs] | 2 +- trunk/drivers/char/moxa.c | 21 +-------------------- 2 files changed, 2 insertions(+), 21 deletions(-) diff --git a/[refs] b/[refs] index 49020625a988..9735d3ea0c2a 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a808ac0c4a2c5d81ba38a2a76d4ddc1de40d1539 +refs/heads/master: f9b412a8c9adb17d50922f91962e8b1e48789430 diff --git a/trunk/drivers/char/moxa.c b/trunk/drivers/char/moxa.c index 7ab720f1f30c..d180aa965a5a 100644 --- a/trunk/drivers/char/moxa.c +++ b/trunk/drivers/char/moxa.c @@ -154,7 +154,6 @@ struct mon_str { #define TXSTOPPED 1 #define LOWWAIT 2 #define EMPTYWAIT 3 -#define THROTTLE 4 #define SERIAL_DO_RESTART @@ -194,8 +193,6 @@ static int moxa_write(struct tty_struct *, const unsigned char *, int); static int moxa_write_room(struct tty_struct *); static void moxa_flush_buffer(struct tty_struct *); static int moxa_chars_in_buffer(struct tty_struct *); -static void moxa_throttle(struct tty_struct *); -static void moxa_unthrottle(struct tty_struct *); static void moxa_set_termios(struct tty_struct *, struct ktermios *); static void moxa_stop(struct tty_struct *); static void moxa_start(struct tty_struct *); @@ -415,8 +412,6 @@ static const struct tty_operations moxa_ops = { .flush_buffer = moxa_flush_buffer, .chars_in_buffer = moxa_chars_in_buffer, .ioctl = moxa_ioctl, - .throttle = moxa_throttle, - .unthrottle = moxa_unthrottle, .set_termios = moxa_set_termios, .stop = moxa_stop, .start = moxa_start, @@ -1327,20 +1322,6 @@ static int moxa_tiocmset(struct tty_struct *tty, struct file *file, return 0; } -static void moxa_throttle(struct tty_struct *tty) -{ - struct moxa_port *ch = tty->driver_data; - - set_bit(THROTTLE, &ch->statusflags); -} - -static void moxa_unthrottle(struct tty_struct *tty) -{ - struct moxa_port *ch = tty->driver_data; - - clear_bit(THROTTLE, &ch->statusflags); -} - static void moxa_set_termios(struct tty_struct *tty, struct ktermios *old_termios) { @@ -1418,7 +1399,7 @@ static int moxa_poll_port(struct moxa_port *p, unsigned int handle, tty_wakeup(tty); } - if (inited && !test_bit(THROTTLE, &p->statusflags) && + if (inited && !test_bit(TTY_THROTTLED, &tty->flags) && MoxaPortRxQueue(p) > 0) { /* RX */ MoxaPortReadData(p); tty_schedule_flip(tty);