1.\" $NetBSD: le.4,v 1.22 2004/10/04 19:12:52 rumble Exp $ 2.\" 3.\"- 4.\" Copyright (c) 1992, 1993 5.\" The Regents of the University of California. All rights reserved. 6.\" 7.\" This software was developed by the Computer Systems Engineering group 8.\" at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and 9.\" contributed to Berkeley. 10.\" 11.\" Redistribution and use in source and binary forms, with or without 12.\" modification, are permitted provided that the following conditions 13.\" are met: 14.\" 1. Redistributions of source code must retain the above copyright 15.\" notice, this list of conditions and the following disclaimer. 16.\" 2. Redistributions in binary form must reproduce the above copyright 17.\" notice, this list of conditions and the following disclaimer in the 18.\" documentation and/or other materials provided with the distribution. 19.\" 3. Neither the name of the University nor the names of its contributors 20.\" may be used to endorse or promote products derived from this software 21.\" without specific prior written permission. 22.\" 23.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 24.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 25.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 26.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 27.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 28.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 29.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 30.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 31.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 32.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 33.\" SUCH DAMAGE. 34.\" 35.\" from: Header: le.4,v 1.2 92/10/13 05:31:33 leres Exp 36.\" from: @(#)le.4 8.1 (Berkeley) 6/9/93 37.\" $FreeBSD: /repoman/r/ncvs/src/share/man/man4/le.4,v 1.2 2006/02/02 14:57:00 marius Exp $ 38.\" 39.Dd July 7, 2006 40.Dt LNC 4 41.Os 42.Sh NAME 43.Nm lnc 44.Nd AMD Am7900 LANCE and Am79C9xx PCnet Ethernet interface driver 45.Sh SYNOPSIS 46.Cd "device lnc" 47.Sh DESCRIPTION 48The 49.Nm 50driver provides support for the AMD family of Lance/PCnet Ethernet NICs 51including the Am7990 and Am79C960. 52.Pp 53The 54.Nm 55driver also supports PCnet adapters based on the 56.Tn AMD 79C9xx 57family of chips, which are single-chip implementations of a 58.Tn LANCE 59chip and a DMA engine. 60This includes a superset of the 61.Tn PCI 62bus Ethernet chip sets supported by the 63.Xr pcn 4 64driver. 65The 66.Nm 67driver treats all of these 68.Tn PCI 69bus Ethernet chip sets as an 70.Tn AMD Am79C970 PCnet-PCI 71and does not support the additional features like the MII bus and burst mode of 72.Tn AMD Am79C971 PCnet-FAST 73and greater chip sets. 74Thus the 75.Xr pcn 4 76driver should be preferred for the latter. 77.Pp 78The 79.Nm 80driver supports reception and transmission of extended frames for 81.Xr vlan 4 . 82Selective reception of multicast Ethernet frames is provided by a 64-bit mask; 83multicast destination addresses are hashed to a bit entry using the Ethernet 84CRC function. 85.Sh HARDWARE 86The 87.Tn PCI 88bus Ethernet chip sets supported by the 89.Nm 90driver are: 91.Pp 92.Bl -bullet -compact 93.It 94.Tn AMD Am53C974/Am79C970/Am79C974 PCnet-PCI 95.It 96.Tn AMD Am79C970A PCnet-PCI II 97.It 98.Tn AMD Am79C971 PCnet-FAST 99.It 100.Tn AMD Am79C972 PCnet-FAST+ 101.It 102.Tn AMD Am79C973/Am79C975 PCnet-FAST III 103.It 104.Tn AMD Am79C976 PCnet-PRO 105.It 106.Tn AMD Am79C978 PCnet-Home 107.El 108.Pp 109The 110.Nm 111driver supports the following media types with these chip sets: 112.Bl -tag -width xxxxxxxxxxxxxxxxxxxx 113.It autoselect 114Enable autoselection of the media type. 115.It 10baseT/UTP 116Select UTP media. 117.It 10base5/AUI 118Select AUI/BNC media. 119.El 120.Pp 121The following media option is supported with these media types: 122.Bl -tag -width xxxxxxxxxxxxxxxxxxxx 123.It full-duplex 124Select full duplex operation. 125.El 126.Pp 127Note that unlike the 128.Xr pcn 4 129driver, the 130.Nm 131driver does not support selecting 100Mbps (Fast Ethernet) media types. 132.Pp 133For further information on configuring media types and options, see 134.Xr ifconfig 8 . 135.Sh DIAGNOSTICS 136.Bl -diag 137.It "lnc%d: overflow" 138More packets came in from the Ethernet than there was space in the 139.Tn LANCE 140receive buffers. 141Packets were missed. 142.It "lnc%d: receive buffer error" 143The 144.Tn LANCE 145ran out of buffer space, packet dropped. 146.It "lnc%d: lost carrier" 147The Ethernet carrier disappeared during an attempt to transmit. 148The 149.Tn LANCE 150will finish transmitting the current packet, 151but will not automatically retry transmission if there is a collision. 152.It "lnc%d: excessive collisions, tdr %d" 153The Ethernet was extremely busy or jammed, 154outbound packets were dropped after 16 attempts to retransmit. 155.Pp 156TDR 157is the abbreviation of 158.Qq Time Domain Reflectometry . 159The optionally reported TDR value is an internal counter of the interval 160between the start of a transmission and the occurrence of a collision. 161This value can be used to determine the distance from the Ethernet tap to 162the point on the Ethernet cable that is shorted or open (unterminated). 163.It "lnc%d: dropping chained buffer" 164A packet did not fit into a single receive buffer and was dropped. 165Since the 166.Nm 167driver allocates buffers large enough to receive maximum sized Ethernet 168packets, this means some other station on the LAN transmitted a packet 169larger than allowed by the Ethernet standard. 170.It "lnc%d: transmit buffer error" 171The 172.Tn LANCE 173ran out of buffer space before finishing the transmission of a packet. 174If this error occurs, the driver software has a bug. 175.It "lnc%d: underflow" 176The 177.Tn LANCE 178ran out of buffer space before finishing the transmission of a packet. 179If this error occurs, the driver software has a bug. 180.It "lnc%d: controller failed to initialize" 181Driver failed to start the 182.Tn LANCE . 183This is potentially a hardware failure. 184.It "lnc%d: memory error" 185RAM failed to respond within the timeout when the 186.Tn LANCE 187wanted to read or write it. 188This is potentially a hardware failure. 189.It "lnc%d: receiver disabled" 190The receiver of the 191.Tn LANCE 192was turned off due to an error. 193.It "lnc%d: transmitter disabled" 194The transmitter of the 195.Tn LANCE 196was turned off due to an error. 197.El 198.Sh SEE ALSO 199.Xr arp 4 , 200.Xr ifmedia 4 , 201.Xr intro 4 , 202.Xr netintro 4 , 203.Xr pcn 4 , 204.Xr vlan 4 , 205.Xr ifconfig 8 206.Sh HISTORY 207The 208.Nm 209driver first appeared in 210.Fx 2.2 , 211it was replaced in 212.Dx 1.5 213with the 214.Xr le 4 215driver from 216.Fx 6.1 217which was in turn ported from 218.Nx . 219The 220.Nx 221driver was derived from the 222.Xr le 4 223driver in 224.Bx 4.4 . 225.Sh AUTHORS 226.An -nosplit 227The 228.Nm 229driver was ported to 230.Fx 231by 232.An Marius Strobl Aq Mt marius@FreeBSD.org 233and later ported to 234.Dx 235by 236.An Bill Marquette Aq Mt bill.marquette@gmail.com . 237.\" .Sh BUGS 238.\" The Am7990 Revision C chips have a bug which causes garbage to be inserted 239.\" in front of the received packet occasionally. 240.\" The work-around is to ignore packets with an invalid destination address 241.\" (garbage will usually not match), by double-checking the destination 242.\" address of every packet in the driver. 243.\" This work-around can be enabled with the 244.\" .Dv LANCE_REVC_BUG 245.\" kernel option. 246.\" .Pp 247.\" When 248.\" .Dv LANCE_REVC_BUG 249.\" is enabled, the 250.\" .Nm 251.\" driver executes one or two calls to an inline Ethernet address comparison 252.\" function for every received packet. 253.\" There is one comparison for each unicast packet, and two comparisons for 254.\" each broadcast packet. 255.\" .Pp 256.\" In summary, the cost of the LANCE_REVC_BUG option is: 257.\" .Bl -enum -compact 258.\" .It 259.\" loss of multicast support, and 260.\" .It 261.\" eight extra 262.\" .Tn CPU 263.\" instructions per received packet, sometimes sixteen, depending on both the 264.\" processor, and the type of packet. 265.\" .El 266.\" .Pp 267.\" Alas, the Am7990 chip is so old that 268.\" .Tn AMD 269.\" has 270.\" .Qq de-archived 271.\" the production information about it; pending a search elsewhere, we do not 272.\" know how to identify the revision C chip from the date codes. 273