aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/serialP.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-03-20 14:24:39 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2012-03-20 14:24:39 -0400
commit843ec558f91b8e8fdb6efc908f2c0506407cc750 (patch)
tree1866dccbc298390fc8686875942324075fd83f9d /include/linux/serialP.h
parent71e7ff2578c3bc67fd893a9ba7f69fd563f271de (diff)
parentfb8ebec00b04f921ea1614a7303f1a8e5e9e47c5 (diff)
Merge tag 'tty-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Pull TTY/serial patches from Greg KH: "tty and serial merge for 3.4-rc1 Here's the big serial and tty merge for the 3.4-rc1 tree. There's loads of fixes and reworks in here from Jiri for the tty layer, and a number of patches from Alan to help try to wrestle the vt layer into a sane model. Other than that, lots of driver updates and fixes, and other minor stuff, all detailed in the shortlog." * tag 'tty-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: (132 commits) serial: pxa: add clk_prepare/clk_unprepare calls TTY: Wrong unicode value copied in con_set_unimap() serial: PL011: clear pending interrupts serial: bfin-uart: Don't access tty circular buffer in TX DMA interrupt after it is reset. vt: NULL dereference in vt_do_kdsk_ioctl() tty: serial: vt8500: fix annotations for probe/remove serial: remove back and forth conversions in serial_out_sync serial: use serial_port_in/out vs serial_in/out in 8250 serial: introduce generic port in/out helpers serial: reduce number of indirections in 8250 code serial: delete useless void casts in 8250.c serial: make 8250's serial_in shareable to other drivers. serial: delete last unused traces of pausing I/O in 8250 pch_uart: Add module parameter descriptions pch_uart: Use existing default_baud in setup_console pch_uart: Add user_uartclk parameter pch_uart: Add Fish River Island II uart clock quirks pch_uart: Use uartclk instead of base_baud mpc5200b/uart: select more tolerant uart prescaler on low baudrates tty: moxa: fix bit test in moxa_start() ...
Diffstat (limited to 'include/linux/serialP.h')
-rw-r--r--include/linux/serialP.h142
1 files changed, 0 insertions, 142 deletions
diff --git a/include/linux/serialP.h b/include/linux/serialP.h
deleted file mode 100644
index e811a615f696..000000000000
--- a/include/linux/serialP.h
+++ /dev/null
@@ -1,142 +0,0 @@
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
28struct serial_state {
29 int magic;
30 int baud_base;
31 unsigned long port;
32 int irq;
33 int flags;
34 int hub6;
35 int type;
36 int line;
37 int revision; /* Chip revision (950) */
38 int xmit_fifo_size;
39 int custom_divisor;
40 int count;
41 u8 *iomem_base;
42 u16 iomem_reg_shift;
43 unsigned short close_delay;
44 unsigned short closing_wait; /* time to wait before closing */
45 struct async_icount icount;
46 int io_type;
47 struct async_struct *info;
48 struct pci_dev *dev;
49};
50
51struct async_struct {
52 int magic;
53 unsigned long port;
54 int hub6;
55 int flags;
56 int xmit_fifo_size;
57 struct serial_state *state;
58 struct tty_struct *tty;
59 int read_status_mask;
60 int ignore_status_mask;
61 int timeout;
62 int quot;
63 int x_char; /* xon/xoff character */
64 int close_delay;
65 unsigned short closing_wait;
66 unsigned short closing_wait2; /* obsolete */
67 int IER; /* Interrupt Enable Register */
68 int MCR; /* Modem control register */
69 int LCR; /* Line control register */
70 int ACR; /* 16950 Additional Control Reg. */
71 unsigned long event;
72 unsigned long last_active;
73 int line;
74 int blocked_open; /* # of blocked opens */
75 struct circ_buf xmit;
76 spinlock_t xmit_lock;
77 u8 *iomem_base;
78 u16 iomem_reg_shift;
79 int io_type;
80 struct work_struct work;
81 struct tasklet_struct tlet;
82#ifdef DECLARE_WAITQUEUE
83 wait_queue_head_t open_wait;
84 wait_queue_head_t close_wait;
85 wait_queue_head_t delta_msr_wait;
86#else
87 struct wait_queue *open_wait;
88 struct wait_queue *close_wait;
89 struct wait_queue *delta_msr_wait;
90#endif
91 struct async_struct *next_port; /* For the linked list */
92 struct async_struct *prev_port;
93};
94
95#define CONFIGURED_SERIAL_PORT(info) ((info)->port || ((info)->iomem_base))
96
97#define SERIAL_MAGIC 0x5301
98#define SSTATE_MAGIC 0x5302
99
100/*
101 * Events are used to schedule things to happen at timer-interrupt
102 * time, instead of at rs interrupt time.
103 */
104#define RS_EVENT_WRITE_WAKEUP 0
105
106/*
107 * Multiport serial configuration structure --- internal structure
108 */
109struct rs_multiport_struct {
110 int port1;
111 unsigned char mask1, match1;
112 int port2;
113 unsigned char mask2, match2;
114 int port3;
115 unsigned char mask3, match3;
116 int port4;
117 unsigned char mask4, match4;
118 int port_monitor;
119};
120
121#if defined(__alpha__) && !defined(CONFIG_PCI)
122/*
123 * Digital did something really horribly wrong with the OUT1 and OUT2
124 * lines on at least some ALPHA's. The failure mode is that if either
125 * is cleared, the machine locks up with endless interrupts.
126 *
127 * This is still used by arch/mips/au1000/common/serial.c for some weird
128 * reason (mips != alpha!)
129 */
130#define ALPHA_KLUDGE_MCR (UART_MCR_OUT2 | UART_MCR_OUT1)
131#elif defined(CONFIG_SBC8560)
132/*
133 * WindRiver did something similarly broken on their SBC8560 board. The
134 * UART tristates its IRQ output while OUT2 is clear, but they pulled
135 * the interrupt line _up_ instead of down, so if we register the IRQ
136 * while the UART is in that state, we die in an IRQ storm. */
137#define ALPHA_KLUDGE_MCR (UART_MCR_OUT2)
138#else
139#define ALPHA_KLUDGE_MCR 0
140#endif
141
142#endif /* _LINUX_SERIAL_H */