1.\" 2.\" Copyright (c) 2003 Marcel Moolenaar 3.\" All rights reserved. 4.\" 5.\" Redistribution and use in source and binary forms, with or without 6.\" modification, are permitted provided that the following conditions 7.\" are met: 8.\" 9.\" 1. Redistributions of source code must retain the above copyright 10.\" notice, this list of conditions and the following disclaimer. 11.\" 2. Redistributions in binary form must reproduce the above copyright 12.\" notice, this list of conditions and the following disclaimer in the 13.\" documentation and/or other materials provided with the distribution. 14.\" 15.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 16.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 17.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 18.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 19.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 20.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25.\" 26.\" $FreeBSD$ 27.\" 28.Dd August 25, 2003 29.Dt UART 4 30.Os 31.\" 32.Sh NAME 33.Nm uart 34.Nd driver for Universal Asynchronous Receiver/Transmitter (UART) devices 35.\" 36.Sh SYNOPSIS 37.Cd "device uart" 38.Pp 39.Cd "device puc" 40.Cd "device uart" 41.\" 42.Sh DESCRIPTION 43The 44.Nm 45device driver provides support for various classes of UARTs implementing the 46EIA RS-232C (CCITT V.24) serial communications interface. 47Each such interface is controlled by a separate and independent instance of 48the 49.Nm 50driver. 51The primary support for devices that contain multiple serial interfaces or 52that contain other functionality besides one or more serial interfaces is 53provided by the 54.Xr puc 4 55device driver. 56However, the serial interfaces of those devices that are managed by the 57.Xr puc 4 58driver are controlled by the 59.Nm 60driver. 61As such, the 62.Xr puc 4 63driver provides umbrella functionality for the 64.Nm 65driver and hides the complexities that are inherent when elementary components 66are packaged together. 67.Pp 68The 69.Nm 70driver has a modular design to allow it to be used on differing hardware and 71for various purposes. 72In the following sections the components are discussed in detail. 73Options are described in the section that covers the component to which each 74option applies. 75.\" 76.Ss CORE COMPONENT 77At the heart of the 78.Nm 79driver is the core component. 80It contains the bus attachments and the low-level interrupt handler. 81.\" 82.Ss HARDWARE DRIVERS 83The core component and the kernel interfaces talk to the hardware through the 84hardware interface. 85This interface serves as an abstraction of the hardware and allows varying 86UARTs to be used for serial communications. 87.\" 88.Ss SYSTEM DEVICES 89System devices are UARTs that have a special purpose by way of hardware 90design or software setup. 91For example, Sun UltraSparc machines use UARTs as their keyboard interface. 92Such an UART cannot be used for general purpose communications. 93Likewise, when the kernel is configured for a serial console, the 94corresponding UART will in turn be a system device so that the kernel can 95output boot messages early on in the boot process. 96.\" 97.Ss KERNEL INTERFACES 98The last but not least of the components is the kernel interface. 99This component ultimately determines how the UART is made visible to the 100kernel in particular and to users in general. 101The default kernel interface is the TTY interface. 102This allows the UART to be used for terminals, modems and serial line IP 103applications. 104System devices, with the notable exception of serial consoles, generally 105have specialized kernel interfaces. 106.\" 107.Sh SEE ALSO 108.Xr puc 4 109.\" 110.Sh HISTORY 111The 112.Nm 113device driver first appeared in 114.Fx 5.2 . 115.Sh AUTHORS 116This manual page was written by 117.An Marcel Moolenaar Aq marcel@xcllnt.net . 118