xref: /csrg-svn/share/man/man4/man4.vax/ec.4 (revision 61597)
1*61597Sbostic.\" Copyright (c) 1983, 1991, 1993
2*61597Sbostic.\"	The Regents of the University of California.  All rights reserved.
320714Smckusick.\"
443582Strent.\" %sccs.include.redist.man%
520714Smckusick.\"
6*61597Sbostic.\"     @(#)ec.4	8.1 (Berkeley) 06/05/93
736756Sbostic.\"
847674Scael.Dd
947674Scael.Dt EC 4 vax
1047674Scael.Os BSD 4.2
1147674Scael.Sh NAME
1247674Scael.Nm ec
1347674Scael.Nd 3Com 10 Mb/s Ethernet interface
1447674Scael.Sh SYNOPSIS
1547674Scael.Cd "device ec0 at uba0 csr 161000 vector ecrint eccollide ecxint flags 0"
1647674Scael.Sh DESCRIPTION
1720714SmckusickThe
1847674Scael.Nm ec
1920714Smckusickinterface provides access to a 10 Mb/s Ethernet network through
2020714Smckusicka 3com controller.
2147674Scael.Pp
2247674ScaelThe hardware has 32 kilobytes of dual-ported memory on the
2347674Scael.Tn UNIBUS .
2420714SmckusickThis memory
2520714Smckusickis used for internal buffering by the board, and the interface code reads
2647674Scaelthe buffer contents directly through the
2747674Scael.Tn UNIBUS .
2847674ScaelThe address of this memory is given in the
2947674Scael.Ar flags
3047674Scaelfield
3126226Skarelsin the configuration file.
3226226SkarelsThe first interface normally has its memory at Unibus address 0.
3347674Scael.Pp
3428258SkarelsEach of the host's network addresses
3547674Scaelis specified at boot time with an
3647674Scael.Dv SIOCSIFADDR
3747674Scael.Xr ioctl 2 .
3847674ScaelThe
3947674Scael.Nm ec
4020714Smckusickinterface employs the address resolution protocol described in
4147674Scael.Xr arp 4
4220714Smckusickto dynamically map between Internet and Ethernet addresses on the local
4320714Smckusicknetwork.
4447674Scael.Pp
4547674ScaelThe interface normally tries to use a
4647674Scael.Dq trailer
4747674Scaelencapsulation
4828258Skarelsto minimize copying data on input and output.
4947674ScaelThe use of trailers is negotiated with
5047674Scael.Tn ARP .
5128258SkarelsThis negotiation may be disabled, on a per-interface basis,
5247674Scaelby setting the
5347674Scael.Dv IFF_NOTRAILERS
5447674Scaelflag with an
5547674Scael.Dv SIOCSIFFLAGS
5647674Scael.Xr ioctl .
5747674Scael.Pp
5820714SmckusickThe interface software implements an exponential backoff algorithm
5920714Smckusickwhen notified of a collision on the cable.  This algorithm utilizes
6047674Scaela 16-bit mask and the
6147674Scael.Tn VAX-11 Ns 's
6247674Scaelinterval timer in calculating a series
6320714Smckusickof random backoff values.  The algorithm is as follows:
6447674Scael.Bl -enum -offset indent
6547674Scael.It
6620714SmckusickInitialize the mask to be all 1's.
6747674Scael.It
6820714SmckusickIf the mask is zero, 16 retries have been made and we give
6920714Smckusickup.
7047674Scael.It
7120714SmckusickShift the mask left one bit and formulate a backoff by
7226225Skarelsmasking the interval timer with the smaller of the complement of this mask
7326225Skarelsand a 5-bit mask, resulting in a pseudo-random number between 0 and 31.
7426225SkarelsThis produces the number of slot times to delay,
7526225Skarelswhere a slot is 51 microseconds.
7647674Scael.It
7720714SmckusickUse the value calculated in step 3 to delay before retransmitting
7826225Skarelsthe packet.
7926225SkarelsThe delay is done in a software busy loop.
8047674Scael.El
8147674Scael.Sh DIAGNOSTICS
8247674Scael.Bl -diag
8347674Scael.It ec%d: send error.
8420714SmckusickAfter 16 retransmissions using the
8520714Smckusickexponential backoff algorithm described above, the packet
8620714Smckusickwas dropped.
8747674Scael.Pp
8847674Scael.It ec%d: input error (offset=%d).
8920714SmckusickThe hardware indicated an error
9020714Smckusickin reading a packet off the cable or an illegally sized packet.
9120714SmckusickThe buffer offset value is printed for debugging purposes.
9247674Scael.Pp
9347674Scael.It ec%d: can't handle af%d.
9420714SmckusickThe interface was handed
9520714Smckusicka message with addresses formatted in an unsuitable address
9620714Smckusickfamily; the packet was dropped.
9747674Scael.El
9847674Scael.Sh SEE ALSO
9947674Scael.Xr netintro 4 ,
10047674Scael.Xr inet 4 ,
10147674Scael.Xr arp 4
10247674Scael.Sh HISTORY
10347674ScaelThe
10447674Scael.Nm
10547674Scaeldriver appeared in
10647674Scael.Bx 4.2 .
10747674Scael.Sh BUGS
10820714SmckusickThe hardware is not capable of talking to itself.  The software
10920714Smckusickimplements local sending and broadcast by sending such packets to the
11020714Smckusickloop interface.  This is a kludge.
11147674Scael.Pp
11220714SmckusickBackoff delays are done in a software busy loop.  This can degrade the
11320714Smckusicksystem if the network experiences frequent collisions.
114