xref: /netbsd-src/share/man/man4/com.4 (revision 6a493d6bc668897c91594964a732d38505b70cbb)
1.\"	$NetBSD: com.4,v 1.21 2012/04/29 07:27:19 tsutsui Exp $
2.\"
3.\" Copyright (c) 1990, 1991 The Regents of the University of California.
4.\" All rights reserved.
5.\"
6.\" This code is derived from software contributed to Berkeley by
7.\" the Systems Programming Group of the University of Utah Computer
8.\" Science Department.
9.\" Redistribution and use in source and binary forms, with or without
10.\" modification, are permitted provided that the following conditions
11.\" are met:
12.\" 1. Redistributions of source code must retain the above copyright
13.\"    notice, this list of conditions and the following disclaimer.
14.\" 2. Redistributions in binary form must reproduce the above copyright
15.\"    notice, this list of conditions and the following disclaimer in the
16.\"    documentation and/or other materials provided with the distribution.
17.\" 3. Neither the name of the University nor the names of its contributors
18.\"    may be used to endorse or promote products derived from this software
19.\"    without specific prior written permission.
20.\"
21.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
22.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
25.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31.\" SUCH DAMAGE.
32.\"
33.\"     from: @(#)dca.4	5.2 (Berkeley) 3/27/91
34.\"
35.Dd April 29, 2012
36.Dt COM 4
37.Os
38.Sh NAME
39.Nm com
40.Nd serial communications interface for
41.Tn RS-232C
42.Sh SYNOPSIS
43.Cd "com0 at isa? port" \&"IO_COM1\&" irq 4
44.Cd "com1 at isa? port" \&"IO_COM2\&" irq 3
45.Cd "com* at acpi?"
46.Cd "com* at cardbus?"
47.Cd "com* at isapnp?"
48.Cd "com* at mca? slot ?"
49.Cd "com* at mhzc?"
50.Cd "com* at ofisa?"
51.Cd "com* at pcmcia?"
52.Cd "com* at pcmcom?"
53.Cd "com* at pnpbios? index ?"
54.Cd "com* at puc? port ?"
55.Cd "com* at xirc?"
56.Cd options COM_HAYESP
57.Cd options PPS_SYNC
58.Cd options PPS_TRAILING_EDGE
59.Cd options RND_COM
60.Ss Amiga
61.Cd "com* at clockport?"
62.Ss Arm32
63.Cd "com0 at mainbus? base 0x00210fe0"
64.Cd "com1 at mainbus? base 0x00210be0"
65.Ss HP 9000/300 and 400 Series
66.Cd "com* at dio? scode ?"
67.Cd "com* at frodo? offset ?"
68.Ss HP 9000/700 and 800 Series
69.Cd "com* at dino?"
70.Cd "com* at gsc?"
71.Cd "com* at ssio?"
72.Ss IBM PowerPC 4xx
73.Cd "com* at opb?"
74.Ss SPARC
75.Cd "com* at ebus?"
76.Cd "com* at obio0"
77.Ss x68k
78.Cd "com0 at intio0 addr 0xefff00 intr 240"
79.Cd "com1 at intio0 addr 0xefff10 intr 241"
80.Sh DESCRIPTION
81The
82.Nm
83driver provides support for NS8250-, NS16450-, and NS16550-based
84.Tn EIA
85.Tn RS-232C
86.Pf ( Tn CCITT
87.Tn V.28 )
88communications interfaces.
89The NS8250 and NS16450 have single character
90buffers, and the NS16550 has a 16 character buffer.
91.Pp
92Input and output for each line may set to one of following baud rates;
9350, 75, 110, 134.5, 150, 300, 600, 1200, 1800, 2400, 4800, 9600,
9419200, 38400, 57600, or 115200, or any other baud rate which is a factor
95of 115200.
96.Pp
97The ttyXX devices are traditional dial-in devices; the dtyXX devices are
98used for dial-out.
99(See
100.Xr tty 4 . )
101.Pp
102.Cd options COM_HAYESP
103adds support for the Hayes ESP serial board.
104.Pp
105.Cd options PPS_SYNC
106enables code to use the Data Carrier Detect (DCD) signal line for attachment
107to an external precision clock source
108.Po
109e.g.,
110.Tn GPS ,
111.Tn CDMA
112.Pc
113which generates a Pulse Per Second (PPS) signal.
114This is used by
115.Xr ntpd 8
116to discipline the system clock, and more accurately count/measure time.
117See
118.Xr options 4
119for more discussion.
120.Pp
121With
122.Cd options RND_COM
123enabled, the
124.Nm
125driver can be used to collect entropy for the
126.Xr rnd 4
127entropy pool.
128The entropy is generated from interrupt randomness.
129.Ss Arm32 specific
130If
131.Dq flags 1
132is specified, the
133.Nm
134driver will not set the
135.Dv MCR_IENABLE
136bit on the UART.
137This is mainly for use on AST multiport boards, where the
138.Dv MCR_IENABLE
139bit is used to control whether or not the devices use a shared
140interrupt.
141.Sh FILES
142.Bl -tag -width Pa -compact
143.It Pa /dev/dty00
144.It Pa /dev/dty01
145.It Pa /dev/dty02
146.It Pa /dev/tty00
147.It Pa /dev/tty01
148.It Pa /dev/tty02
149.El
150.Sh DIAGNOSTICS
151.Bl -diag
152.It com%d: %d silo overflows
153The input
154.Dq silo
155has overflowed and incoming data has been lost.
156.It com%d: weird interrupt: iir=%x
157The device has generated an unexpected interrupt
158with the code listed.
159.El
160.Sh SEE ALSO
161.Xr acpi 4 ,
162.Xr ast 4 ,
163.Xr cardbus 4 ,
164.Xr isa 4 ,
165.Xr isapnp 4 ,
166.Xr mca 4 ,
167.Xr mhzc 4 ,
168.Xr ofisa 4 ,
169.Xr options 4 ,
170.Xr pcmcia 4 ,
171.Xr pcmcom 4 ,
172.Xr pnpbios 4 ,
173.Xr puc 4 ,
174.Xr rtfps 4 ,
175.Xr tty 4 ,
176.Xr xirc 4 ,
177.Xr ntpd 8
178.Sh HISTORY
179The
180.Nm
181driver was originally derived from the HP9000/300
182.Ic dca
183driver.
184.Sh BUGS
185Data loss is possible on busy systems with unbuffered UARTs at high speed.
186.Pp
187The name of this driver and the constants which define the locations
188of the various serial ports are holdovers from
189.Tn DOS .
190