diff options
author | Alan Cox <alan@redhat.com> | 2008-07-16 16:52:25 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-20 20:12:34 -0400 |
commit | 15648f154a8faea97cbe931e189cf0a57fd066f4 (patch) | |
tree | bf5a9abe190c1a9eec33270f48280e0e44201e84 /arch/ia64 | |
parent | 5b664cb235e97afbf34db9c4d77f08ebd725335e (diff) |
simserial: Fix up for ldisc changes
Noted by Tony Luck although I've done the patches differently and also
removed some other bogus oddments.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/ia64')
-rw-r--r-- | arch/ia64/hp/sim/simserial.c | 46 |
1 files changed, 3 insertions, 43 deletions
diff --git a/arch/ia64/hp/sim/simserial.c b/arch/ia64/hp/sim/simserial.c index 23cafc80d2a4..24b1ad5334cb 100644 --- a/arch/ia64/hp/sim/simserial.c +++ b/arch/ia64/hp/sim/simserial.c | |||
@@ -193,18 +193,6 @@ static irqreturn_t rs_interrupt_single(int irq, void *dev_id) | |||
193 | * ------------------------------------------------------------------- | 193 | * ------------------------------------------------------------------- |
194 | */ | 194 | */ |
195 | 195 | ||
196 | #if 0 | ||
197 | /* | ||
198 | * not really used in our situation so keep them commented out for now | ||
199 | */ | ||
200 | static DECLARE_TASK_QUEUE(tq_serial); /* used to be at the top of the file */ | ||
201 | static void do_serial_bh(void) | ||
202 | { | ||
203 | run_task_queue(&tq_serial); | ||
204 | printk(KERN_ERR "do_serial_bh: called\n"); | ||
205 | } | ||
206 | #endif | ||
207 | |||
208 | static void do_softint(struct work_struct *private_) | 196 | static void do_softint(struct work_struct *private_) |
209 | { | 197 | { |
210 | printk(KERN_ERR "simserial: do_softint called\n"); | 198 | printk(KERN_ERR "simserial: do_softint called\n"); |
@@ -351,11 +339,7 @@ static void rs_flush_buffer(struct tty_struct *tty) | |||
351 | info->xmit.head = info->xmit.tail = 0; | 339 | info->xmit.head = info->xmit.tail = 0; |
352 | local_irq_restore(flags); | 340 | local_irq_restore(flags); |
353 | 341 | ||
354 | wake_up_interruptible(&tty->write_wait); | 342 | tty_wakeup(tty); |
355 | |||
356 | if ((tty->flags & (1 << TTY_DO_WRITE_WAKEUP)) && | ||
357 | tty->ldisc.write_wakeup) | ||
358 | (tty->ldisc.write_wakeup)(tty); | ||
359 | } | 343 | } |
360 | 344 | ||
361 | /* | 345 | /* |
@@ -404,12 +388,6 @@ static void rs_unthrottle(struct tty_struct * tty) | |||
404 | printk(KERN_INFO "simrs_unthrottle called\n"); | 388 | printk(KERN_INFO "simrs_unthrottle called\n"); |
405 | } | 389 | } |
406 | 390 | ||
407 | /* | ||
408 | * rs_break() --- routine which turns the break handling on or off | ||
409 | */ | ||
410 | static void rs_break(struct tty_struct *tty, int break_state) | ||
411 | { | ||
412 | } | ||
413 | 391 | ||
414 | static int rs_ioctl(struct tty_struct *tty, struct file * file, | 392 | static int rs_ioctl(struct tty_struct *tty, struct file * file, |
415 | unsigned int cmd, unsigned long arg) | 393 | unsigned int cmd, unsigned long arg) |
@@ -422,14 +400,6 @@ static int rs_ioctl(struct tty_struct *tty, struct file * file, | |||
422 | } | 400 | } |
423 | 401 | ||
424 | switch (cmd) { | 402 | switch (cmd) { |
425 | case TIOCMGET: | ||
426 | printk(KERN_INFO "rs_ioctl: TIOCMGET called\n"); | ||
427 | return -EINVAL; | ||
428 | case TIOCMBIS: | ||
429 | case TIOCMBIC: | ||
430 | case TIOCMSET: | ||
431 | printk(KERN_INFO "rs_ioctl: TIOCMBIS/BIC/SET called\n"); | ||
432 | return -EINVAL; | ||
433 | case TIOCGSERIAL: | 403 | case TIOCGSERIAL: |
434 | printk(KERN_INFO "simrs_ioctl TIOCGSERIAL called\n"); | 404 | printk(KERN_INFO "simrs_ioctl TIOCGSERIAL called\n"); |
435 | return 0; | 405 | return 0; |
@@ -488,14 +458,6 @@ static int rs_ioctl(struct tty_struct *tty, struct file * file, | |||
488 | 458 | ||
489 | static void rs_set_termios(struct tty_struct *tty, struct ktermios *old_termios) | 459 | static void rs_set_termios(struct tty_struct *tty, struct ktermios *old_termios) |
490 | { | 460 | { |
491 | unsigned int cflag = tty->termios->c_cflag; | ||
492 | |||
493 | if ( (cflag == old_termios->c_cflag) | ||
494 | && ( RELEVANT_IFLAG(tty->termios->c_iflag) | ||
495 | == RELEVANT_IFLAG(old_termios->c_iflag))) | ||
496 | return; | ||
497 | |||
498 | |||
499 | /* Handle turning off CRTSCTS */ | 461 | /* Handle turning off CRTSCTS */ |
500 | if ((old_termios->c_cflag & CRTSCTS) && | 462 | if ((old_termios->c_cflag & CRTSCTS) && |
501 | !(tty->termios->c_cflag & CRTSCTS)) { | 463 | !(tty->termios->c_cflag & CRTSCTS)) { |
@@ -623,9 +585,8 @@ static void rs_close(struct tty_struct *tty, struct file * filp) | |||
623 | * the line discipline to only process XON/XOFF characters. | 585 | * the line discipline to only process XON/XOFF characters. |
624 | */ | 586 | */ |
625 | shutdown(info); | 587 | shutdown(info); |
626 | if (tty->ops->flush_buffer) | 588 | rs_flush_buffer(tty); |
627 | tty->ops->flush_buffer(tty); | 589 | tty_ldisc_flush(tty); |
628 | if (tty->ldisc.flush_buffer) tty->ldisc.flush_buffer(tty); | ||
629 | info->event = 0; | 590 | info->event = 0; |
630 | info->tty = NULL; | 591 | info->tty = NULL; |
631 | if (info->blocked_open) { | 592 | if (info->blocked_open) { |
@@ -955,7 +916,6 @@ static const struct tty_operations hp_ops = { | |||
955 | .stop = rs_stop, | 916 | .stop = rs_stop, |
956 | .start = rs_start, | 917 | .start = rs_start, |
957 | .hangup = rs_hangup, | 918 | .hangup = rs_hangup, |
958 | .break_ctl = rs_break, | ||
959 | .wait_until_sent = rs_wait_until_sent, | 919 | .wait_until_sent = rs_wait_until_sent, |
960 | .read_proc = rs_read_proc, | 920 | .read_proc = rs_read_proc, |
961 | }; | 921 | }; |