blob: 300176b231737e70dd1fcee0bcea2c8abf1a9dcf [file] [log] [blame]
Ben Cheng655a7c02013-10-16 16:09:24 -07001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 *** To edit the content of this header, modify the corresponding
11 *** source file (e.g. under external/kernel-headers/original/) then
12 *** run bionic/libc/kernel/tools/update_all.py
13 ***
14 *** Any manual change here will be lost the next time this script will
15 *** be run. You've been warned!
16 ***
17 ****************************************************************************
18 ****************************************************************************/
19#ifndef _UAPI_LINUX_SERIAL_H
20#define _UAPI_LINUX_SERIAL_H
21#include <linux/types.h>
22#include <linux/tty_flags.h>
23/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
24struct serial_struct {
Tao Baod7db5942015-01-28 10:07:51 -080025 int type;
26 int line;
27 unsigned int port;
Ben Cheng655a7c02013-10-16 16:09:24 -070028/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080029 int irq;
30 int flags;
31 int xmit_fifo_size;
32 int custom_divisor;
Ben Cheng655a7c02013-10-16 16:09:24 -070033/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080034 int baud_base;
35 unsigned short close_delay;
36 char io_type;
37 char reserved_char[1];
Ben Cheng655a7c02013-10-16 16:09:24 -070038/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080039 int hub6;
40 unsigned short closing_wait;
41 unsigned short closing_wait2;
42 unsigned char * iomem_base;
Ben Cheng655a7c02013-10-16 16:09:24 -070043/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080044 unsigned short iomem_reg_shift;
45 unsigned int port_high;
46 unsigned long iomap_base;
Ben Cheng655a7c02013-10-16 16:09:24 -070047};
48/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
49#define ASYNC_CLOSING_WAIT_INF 0
50#define ASYNC_CLOSING_WAIT_NONE 65535
51#define PORT_UNKNOWN 0
52#define PORT_8250 1
53/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
54#define PORT_16450 2
55#define PORT_16550 3
56#define PORT_16550A 4
57#define PORT_CIRRUS 5
58/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
59#define PORT_16650 6
60#define PORT_16650V2 7
61#define PORT_16750 8
62#define PORT_STARTECH 9
63/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
64#define PORT_16C950 10
65#define PORT_16654 11
66#define PORT_16850 12
67#define PORT_RSA 13
68/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
69#define PORT_MAX 13
70#define SERIAL_IO_PORT 0
71#define SERIAL_IO_HUB6 1
72#define SERIAL_IO_MEM 2
73/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
74#define UART_CLEAR_FIFO 0x01
75#define UART_USE_FIFO 0x02
76#define UART_STARTECH 0x04
77#define UART_NATSEMI 0x08
78/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
79struct serial_multiport_struct {
Tao Baod7db5942015-01-28 10:07:51 -080080 int irq;
81 int port1;
82 unsigned char mask1, match1;
Ben Cheng655a7c02013-10-16 16:09:24 -070083/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080084 int port2;
85 unsigned char mask2, match2;
86 int port3;
87 unsigned char mask3, match3;
Ben Cheng655a7c02013-10-16 16:09:24 -070088/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080089 int port4;
90 unsigned char mask4, match4;
91 int port_monitor;
92 int reserved[32];
Ben Cheng655a7c02013-10-16 16:09:24 -070093/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
94};
95struct serial_icounter_struct {
Tao Baod7db5942015-01-28 10:07:51 -080096 int cts, dsr, rng, dcd;
97 int rx, tx;
Ben Cheng655a7c02013-10-16 16:09:24 -070098/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -080099 int frame, overrun, parity, brk;
100 int buf_overrun;
101 int reserved[9];
Ben Cheng655a7c02013-10-16 16:09:24 -0700102};
103/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
104struct serial_rs485 {
Tao Baod7db5942015-01-28 10:07:51 -0800105 __u32 flags;
Ben Cheng655a7c02013-10-16 16:09:24 -0700106#define SER_RS485_ENABLED (1 << 0)
107#define SER_RS485_RTS_ON_SEND (1 << 1)
108/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
109#define SER_RS485_RTS_AFTER_SEND (1 << 2)
110#define SER_RS485_RX_DURING_TX (1 << 4)
Tao Baod7db5942015-01-28 10:07:51 -0800111 __u32 delay_rts_before_send;
112 __u32 delay_rts_after_send;
Ben Cheng655a7c02013-10-16 16:09:24 -0700113/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
Tao Baod7db5942015-01-28 10:07:51 -0800114 __u32 padding[5];
Ben Cheng655a7c02013-10-16 16:09:24 -0700115};
116#endif