(CFLAGS-tst-align.c): Add -mpreferred-stack-boundary=4.
[glibc.git] / sysdeps / unix / sysv / linux / sparc / bits / termios.h
blob16f76dfa54c5090d7e4a77398add6c1ad74ccb5c
1 /* termios type and macro definitions. Linux/SPARC version.
2 Copyright (C) 1993, 1994, 1995, 1996, 1997, 2000 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, write to the Free
17 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
18 02111-1307 USA. */
20 #ifndef _TERMIOS_H
21 # error "Never include <bits/termios.h> directly; use <termios.h> instead."
22 #endif
24 typedef unsigned char cc_t;
25 typedef unsigned int speed_t;
26 typedef unsigned int tcflag_t;
28 #define NCCS 17
29 struct termios
31 tcflag_t c_iflag; /* input mode flags */
32 tcflag_t c_oflag; /* output mode flags */
33 tcflag_t c_cflag; /* control mode flags */
34 tcflag_t c_lflag; /* local mode flags */
35 cc_t c_line; /* line discipline */
36 cc_t c_cc[NCCS]; /* control characters */
39 /* c_cc characters */
40 #define VINTR 0
41 #define VQUIT 1
42 #define VERASE 2
43 #define VKILL 3
44 #define VEOF 4
45 #define VEOL 5
46 #define VEOL2 6
47 #define VSWTC 7
48 #define VSTART 8
49 #define VSTOP 9
50 #define VSUSP 10
51 #define VDSUSP 11 /* SunOS POSIX nicety I do believe... */
52 #define VREPRINT 12
53 #define VDISCARD 13
54 #define VWERASE 14
55 #define VLNEXT 15
57 /* User apps assume vmin/vtime is shared with eof/eol */
58 #define VMIN VEOF
59 #define VTIME VEOL
61 /* c_iflag bits */
62 #define IGNBRK 0x00000001
63 #define BRKINT 0x00000002
64 #define IGNPAR 0x00000004
65 #define PARMRK 0x00000008
66 #define INPCK 0x00000010
67 #define ISTRIP 0x00000020
68 #define INLCR 0x00000040
69 #define IGNCR 0x00000080
70 #define ICRNL 0x00000100
71 #define IUCLC 0x00000200
72 #define IXON 0x00000400
73 #define IXANY 0x00000800
74 #define IXOFF 0x00001000
75 #define IMAXBEL 0x00002000
76 #define IUTF8 0x00004000
78 /* c_oflag bits */
79 #define OPOST 0x00000001
80 #define OLCUC 0x00000002
81 #define ONLCR 0x00000004
82 #define OCRNL 0x00000008
83 #define ONOCR 0x00000010
84 #define ONLRET 0x00000020
85 #define OFILL 0x00000040
86 #define OFDEL 0x00000080
87 #define NLDLY 0x00000100
88 #define NL0 0x00000000
89 #define NL1 0x00000100
90 #define CRDLY 0x00000600
91 #define CR0 0x00000000
92 #define CR1 0x00000200
93 #define CR2 0x00000400
94 #define CR3 0x00000600
95 #define TABDLY 0x00001800
96 #define TAB0 0x00000000
97 #define TAB1 0x00000800
98 #define TAB2 0x00001000
99 #define TAB3 0x00001800
100 #define XTABS 0x00001800
101 #define BSDLY 0x00002000
102 #define BS0 0x00000000
103 #define BS1 0x00002000
104 #define VTDLY 0x00004000
105 #define VT0 0x00000000
106 #define VT1 0x00004000
107 #define FFDLY 0x00008000
108 #define FF0 0x00000000
109 #define FF1 0x00008000
110 #define PAGEOUT 0x00010000 /* SUNOS specific */
111 #define WRAP 0x00020000 /* SUNOS specific */
113 /* c_cflag bit meaning */
114 #define CBAUD 0x0000100f
115 #define B0 0x00000000 /* hang up */
116 #define B50 0x00000001
117 #define B75 0x00000002
118 #define B110 0x00000003
119 #define B134 0x00000004
120 #define B150 0x00000005
121 #define B200 0x00000006
122 #define B300 0x00000007
123 #define B600 0x00000008
124 #define B1200 0x00000009
125 #define B1800 0x0000000a
126 #define B2400 0x0000000b
127 #define B4800 0x0000000c
128 #define B9600 0x0000000d
129 #define B19200 0x0000000e
130 #define B38400 0x0000000f
131 #define EXTA B19200
132 #define EXTB B38400
133 #define CSIZE 0x00000030
134 #define CS5 0x00000000
135 #define CS6 0x00000010
136 #define CS7 0x00000020
137 #define CS8 0x00000030
138 #define CSTOPB 0x00000040
139 #define CREAD 0x00000080
140 #define PARENB 0x00000100
141 #define PARODD 0x00000200
142 #define HUPCL 0x00000400
143 #define CLOCAL 0x00000800
144 #define CBAUDEX 0x00001000
145 #define B57600 0x00001001
146 #define B115200 0x00001002
147 #define B230400 0x00001003
148 #define B460800 0x00001004
149 #define B76800 0x00001005
150 #define B153600 0x00001006
151 #define B307200 0x00001007
152 #define B614400 0x00001008
153 #define B921600 0x00001009
154 #define B500000 0x0000100a
155 #define B576000 0x0000100b
156 #define B1000000 0x0000100c
157 #define B1152000 0x0000100d
158 #define B1500000 0x0000100e
159 #define B2000000 0x0000100f
160 #define __MAX_BAUD B2000000
162 #define CIBAUD 0x100f0000 /* input baud rate (not used) */
163 #define CMSPAR 0x40000000 /* mark or space (stick) parity */
164 #define CRTSCTS 0x80000000 /* flow control */
166 /* c_lflag bits */
167 #define ISIG 0x00000001
168 #define ICANON 0x00000002
169 #define XCASE 0x00000004
170 #define ECHO 0x00000008
171 #define ECHOE 0x00000010
172 #define ECHOK 0x00000020
173 #define ECHONL 0x00000040
174 #define NOFLSH 0x00000080
175 #define TOSTOP 0x00000100
176 #define ECHOCTL 0x00000200
177 #define ECHOPRT 0x00000400
178 #define ECHOKE 0x00000800
179 #define DEFECHO 0x00001000 /* SUNOS thing, what is it? */
180 #define FLUSHO 0x00002000
181 #define PENDIN 0x00004000
182 #define IEXTEN 0x00008000
184 /* modem lines */
185 #define TIOCM_LE 0x001
186 #define TIOCM_DTR 0x002
187 #define TIOCM_RTS 0x004
188 #define TIOCM_ST 0x008
189 #define TIOCM_SR 0x010
190 #define TIOCM_CTS 0x020
191 #define TIOCM_CAR 0x040
192 #define TIOCM_RNG 0x080
193 #define TIOCM_DSR 0x100
194 #define TIOCM_CD TIOCM_CAR
195 #define TIOCM_RI TIOCM_RNG
197 /* ioctl (fd, TIOCSERGETLSR, &result) where result may be as below */
198 #define TIOCSER_TEMT 0x01 /* Transmitter physically empty */
201 /* tcflow() and TCXONC use these */
202 #define TCOOFF 0
203 #define TCOON 1
204 #define TCIOFF 2
205 #define TCION 3
207 /* tcflush() and TCFLSH use these */
208 #define TCIFLUSH 0
209 #define TCOFLUSH 1
210 #define TCIOFLUSH 2
212 /* tcsetattr uses these */
213 #define TCSANOW 0
214 #define TCSADRAIN 1
215 #define TCSAFLUSH 2