aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/tty_driver.h
diff options
context:
space:
mode:
authorAlan Cox <alan@redhat.com>2008-10-13 05:38:18 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-10-13 12:51:40 -0400
commit1d65b4a088de407e99714fdc27862449db04fb5c (patch)
tree89f378767b9e0fe1a902d73bf43be382c6110f72 /include/linux/tty_driver.h
parent5aaa70a80f5bbfcc4d6a1f844bdd1c5d6b445b5f (diff)
tty: Add termiox
We need a way to describe the various additional modes and flow control features that random weird hardware shows up and software such as wine wants to emulate as Windows supports them. TCGETX/TCSETX and the termiox ioctl are a SYS5 extension that we might as well adopt. This patches adds the structures and the basic ioctl interfaces when the TCGETX etc defines are added for an architecture. Drivers wishing to use this stuff need to add new methods. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/tty_driver.h')
-rw-r--r--include/linux/tty_driver.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/tty_driver.h b/include/linux/tty_driver.h
index 16d27944c32..ac6e58e26b7 100644
--- a/include/linux/tty_driver.h
+++ b/include/linux/tty_driver.h
@@ -180,6 +180,14 @@
180 * not force errors here if they are not resizable objects (eg a serial 180 * not force errors here if they are not resizable objects (eg a serial
181 * line). See tty_do_resize() if you need to wrap the standard method 181 * line). See tty_do_resize() if you need to wrap the standard method
182 * in your own logic - the usual case. 182 * in your own logic - the usual case.
183 *
184 * void (*set_termiox)(struct tty_struct *tty, struct termiox *new);
185 *
186 * Called when the device receives a termiox based ioctl. Passes down
187 * the requested data from user space. This method will not be invoked
188 * unless the tty also has a valid tty->termiox pointer.
189 *
190 * Optional: Called under the termios lock
183 */ 191 */
184 192
185#include <linux/fs.h> 193#include <linux/fs.h>
@@ -220,6 +228,7 @@ struct tty_operations {
220 unsigned int set, unsigned int clear); 228 unsigned int set, unsigned int clear);
221 int (*resize)(struct tty_struct *tty, struct tty_struct *real_tty, 229 int (*resize)(struct tty_struct *tty, struct tty_struct *real_tty,
222 struct winsize *ws); 230 struct winsize *ws);
231 int (*set_termiox)(struct tty_struct *tty, struct termiox *tnew);
223#ifdef CONFIG_CONSOLE_POLL 232#ifdef CONFIG_CONSOLE_POLL
224 int (*poll_init)(struct tty_driver *driver, int line, char *options); 233 int (*poll_init)(struct tty_driver *driver, int line, char *options);
225 int (*poll_get_char)(struct tty_driver *driver, int line); 234 int (*poll_get_char)(struct tty_driver *driver, int line);