aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/synclink_gt.c
diff options
context:
space:
mode:
authorAlan Cox <alan@lxorguk.ukuu.org.uk>2006-12-08 05:38:45 -0500
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-08 11:28:57 -0500
commit606d099cdd1080bbb50ea50dc52d98252f8f10a1 (patch)
tree80d17450a5fb78effce3f4312f672c058658e004 /drivers/char/synclink_gt.c
parentedc6afc5496875a640bef0913604be7550c1795d (diff)
[PATCH] tty: switch to ktermios
This is the grungy swap all the occurrences in the right places patch that goes with the updates. At this point we have the same functionality as before (except that sgttyb() returns speeds not zero) and are ready to begin turning new stuff on providing nobody reports lots of bugs If you are a tty driver author converting an out of tree driver the only impact should be termios->ktermios name changes for the speed/property setting functions from your upper layers. If you are implementing your own TCGETS function before then your driver was broken already and its about to get a whole lot more painful for you so please fix it 8) Also fill in c_ispeed/ospeed on init for most devices, although the current code will do this for you anyway but I'd like eventually to lose that extra paranoia [akpm@osdl.org: bluetooth fix] [mp3@de.ibm.com: sclp fix] [mp3@de.ibm.com: warning fix for tty3270] [hugh@veritas.com: fix tty_ioctl powerpc build] [jdike@addtoit.com: uml: fix ->set_termios declaration] Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Martin Peschke <mp3@de.ibm.com> Acked-by: Peter Oberparleiter <oberpar@de.ibm.com> Cc: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Hugh Dickins <hugh@veritas.com> Signed-off-by: Jeff Dike <jdike@addtoit.com> Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/char/synclink_gt.c')
-rw-r--r--drivers/char/synclink_gt.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/char/synclink_gt.c b/drivers/char/synclink_gt.c
index e4730a7312b..792c79c315e 100644
--- a/drivers/char/synclink_gt.c
+++ b/drivers/char/synclink_gt.c
@@ -151,7 +151,7 @@ static struct tty_driver *serial_driver;
151static int open(struct tty_struct *tty, struct file * filp); 151static int open(struct tty_struct *tty, struct file * filp);
152static void close(struct tty_struct *tty, struct file * filp); 152static void close(struct tty_struct *tty, struct file * filp);
153static void hangup(struct tty_struct *tty); 153static void hangup(struct tty_struct *tty);
154static void set_termios(struct tty_struct *tty, struct termios *old_termios); 154static void set_termios(struct tty_struct *tty, struct ktermios *old_termios);
155 155
156static int write(struct tty_struct *tty, const unsigned char *buf, int count); 156static int write(struct tty_struct *tty, const unsigned char *buf, int count);
157static void put_char(struct tty_struct *tty, unsigned char ch); 157static void put_char(struct tty_struct *tty, unsigned char ch);
@@ -816,7 +816,7 @@ static void hangup(struct tty_struct *tty)
816 wake_up_interruptible(&info->open_wait); 816 wake_up_interruptible(&info->open_wait);
817} 817}
818 818
819static void set_termios(struct tty_struct *tty, struct termios *old_termios) 819static void set_termios(struct tty_struct *tty, struct ktermios *old_termios)
820{ 820{
821 struct slgt_info *info = tty->driver_data; 821 struct slgt_info *info = tty->driver_data;
822 unsigned long flags; 822 unsigned long flags;
@@ -3546,6 +3546,8 @@ static int __init slgt_init(void)
3546 serial_driver->init_termios = tty_std_termios; 3546 serial_driver->init_termios = tty_std_termios;
3547 serial_driver->init_termios.c_cflag = 3547 serial_driver->init_termios.c_cflag =
3548 B9600 | CS8 | CREAD | HUPCL | CLOCAL; 3548 B9600 | CS8 | CREAD | HUPCL | CLOCAL;
3549 serial_driver->init_termios.c_ispeed = 9600;
3550 serial_driver->init_termios.c_ospeed = 9600;
3549 serial_driver->flags = TTY_DRIVER_REAL_RAW; 3551 serial_driver->flags = TTY_DRIVER_REAL_RAW;
3550 tty_set_operations(serial_driver, &ops); 3552 tty_set_operations(serial_driver, &ops);
3551 if ((rc = tty_register_driver(serial_driver)) < 0) { 3553 if ((rc = tty_register_driver(serial_driver)) < 0) {