diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2008-02-08 07:18:40 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-08 12:22:24 -0500 |
commit | 596f56018df3ed7de20f6038f72177b3674ebbd4 (patch) | |
tree | 8d3956e81dd291e5c01d27d76d5b0dfb9febd38b /include/asm-s390 | |
parent | aa7738a5f503abea5445cdd8cc2d501502c748ae (diff) |
tty: s390 support for termios2.
Backend for s390.
Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/asm-s390')
-rw-r--r-- | include/asm-s390/ioctls.h | 4 | ||||
-rw-r--r-- | include/asm-s390/termbits.h | 5 | ||||
-rw-r--r-- | include/asm-s390/termios.h | 3 |
3 files changed, 11 insertions, 1 deletions
diff --git a/include/asm-s390/ioctls.h b/include/asm-s390/ioctls.h index 07e19b2dd73f..40e481b1b461 100644 --- a/include/asm-s390/ioctls.h +++ b/include/asm-s390/ioctls.h | |||
@@ -54,6 +54,10 @@ | |||
54 | #define TIOCSBRK 0x5427 /* BSD compatibility */ | 54 | #define TIOCSBRK 0x5427 /* BSD compatibility */ |
55 | #define TIOCCBRK 0x5428 /* BSD compatibility */ | 55 | #define TIOCCBRK 0x5428 /* BSD compatibility */ |
56 | #define TIOCGSID 0x5429 /* Return the session ID of FD */ | 56 | #define TIOCGSID 0x5429 /* Return the session ID of FD */ |
57 | #define TCGETS2 _IOR('T',0x2A, struct termios2) | ||
58 | #define TCSETS2 _IOW('T',0x2B, struct termios2) | ||
59 | #define TCSETSW2 _IOW('T',0x2C, struct termios2) | ||
60 | #define TCSETSF2 _IOW('T',0x2D, struct termios2) | ||
57 | #define TIOCGPTN _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */ | 61 | #define TIOCGPTN _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */ |
58 | #define TIOCSPTLCK _IOW('T',0x31, int) /* Lock/unlock Pty */ | 62 | #define TIOCSPTLCK _IOW('T',0x31, int) /* Lock/unlock Pty */ |
59 | 63 | ||
diff --git a/include/asm-s390/termbits.h b/include/asm-s390/termbits.h index 811b9a9cdc08..58731853d529 100644 --- a/include/asm-s390/termbits.h +++ b/include/asm-s390/termbits.h | |||
@@ -148,6 +148,7 @@ struct ktermios { | |||
148 | #define HUPCL 0002000 | 148 | #define HUPCL 0002000 |
149 | #define CLOCAL 0004000 | 149 | #define CLOCAL 0004000 |
150 | #define CBAUDEX 0010000 | 150 | #define CBAUDEX 0010000 |
151 | #define BOTHER 0010000 | ||
151 | #define B57600 0010001 | 152 | #define B57600 0010001 |
152 | #define B115200 0010002 | 153 | #define B115200 0010002 |
153 | #define B230400 0010003 | 154 | #define B230400 0010003 |
@@ -163,10 +164,12 @@ struct ktermios { | |||
163 | #define B3000000 0010015 | 164 | #define B3000000 0010015 |
164 | #define B3500000 0010016 | 165 | #define B3500000 0010016 |
165 | #define B4000000 0010017 | 166 | #define B4000000 0010017 |
166 | #define CIBAUD 002003600000 /* input baud rate (not used) */ | 167 | #define CIBAUD 002003600000 /* input baud rate */ |
167 | #define CMSPAR 010000000000 /* mark or space (stick) parity */ | 168 | #define CMSPAR 010000000000 /* mark or space (stick) parity */ |
168 | #define CRTSCTS 020000000000 /* flow control */ | 169 | #define CRTSCTS 020000000000 /* flow control */ |
169 | 170 | ||
171 | #define IBSHIFT 16 /* Shift from CBAUD to CIBAUD */ | ||
172 | |||
170 | /* c_lflag bits */ | 173 | /* c_lflag bits */ |
171 | #define ISIG 0000001 | 174 | #define ISIG 0000001 |
172 | #define ICANON 0000002 | 175 | #define ICANON 0000002 |
diff --git a/include/asm-s390/termios.h b/include/asm-s390/termios.h index a3480e25eb4b..67f66278f533 100644 --- a/include/asm-s390/termios.h +++ b/include/asm-s390/termios.h | |||
@@ -57,6 +57,9 @@ struct termio { | |||
57 | */ | 57 | */ |
58 | #define INIT_C_CC "\003\034\177\025\004\0\1\0\021\023\032\0\022\017\027\026\0" | 58 | #define INIT_C_CC "\003\034\177\025\004\0\1\0\021\023\032\0\022\017\027\026\0" |
59 | 59 | ||
60 | #define user_termios_to_kernel_termios(k, u) copy_from_user(k, u, sizeof(struct termios2)) | ||
61 | #define kernel_termios_to_user_termios(u, k) copy_to_user(u, k, sizeof(struct termios2)) | ||
62 | |||
60 | #include <asm-generic/termios.h> | 63 | #include <asm-generic/termios.h> |
61 | 64 | ||
62 | #endif /* __KERNEL__ */ | 65 | #endif /* __KERNEL__ */ |