]> Pileus Git - ~andy/linux/blob - include/linux/serialP.h
TTY: simserial, pass tty down to functions
[~andy/linux] / include / linux / serialP.h
1 /*
2  * Private header file for the (dumb) serial driver
3  *
4  * Copyright (C) 1997 by Theodore Ts'o.
5  * 
6  * Redistribution of this file is permitted under the terms of the GNU 
7  * Public License (GPL)
8  */
9
10 #ifndef _LINUX_SERIALP_H
11 #define _LINUX_SERIALP_H
12
13 /*
14  * This is our internal structure for each serial port's state.
15  * 
16  * Many fields are paralleled by the structure used by the serial_struct
17  * structure.
18  *
19  * For definitions of the flags field, see tty.h
20  */
21
22 #include <linux/termios.h>
23 #include <linux/workqueue.h>
24 #include <linux/interrupt.h>
25 #include <linux/circ_buf.h>
26 #include <linux/wait.h>
27
28 struct serial_state {
29         int     baud_base;
30         unsigned long   port;
31         int     irq;
32         int     flags;
33         int     type;
34         int     line;
35         int     xmit_fifo_size;
36         int     custom_divisor;
37         int     count;
38         unsigned short  close_delay;
39         unsigned short  closing_wait; /* time to wait before closing */
40         struct async_icount     icount; 
41
42         /* amiserial */
43         int                     read_status_mask;
44         int                     ignore_status_mask;
45         int                     timeout;
46         int                     quot;
47         int                     IER;    /* Interrupt Enable Register */
48         int                     MCR;    /* Modem control register */
49         wait_queue_head_t       delta_msr_wait;
50         /* simserial */
51         int                     x_char; /* xon/xoff character */
52         int                     blocked_open; /* # of blocked opens */
53         struct circ_buf         xmit;
54         wait_queue_head_t       open_wait;
55         wait_queue_head_t       close_wait;
56         struct tty_struct       *tty;
57         /* /simserial */
58         /* /amiserial */
59 };
60
61 #endif /* _LINUX_SERIAL_H */