目录

Documentationnetworking3c509.txt

目录

Documentation/networking/3c509.txt

Chinese translated version of Documentation/networking/3c509.txt

If you have any comment or update to the content, please contact the

original document maintainer directly.  However, if you have a problem

communicating in English you can also ask the Chinese maintainer for

help.  Contact the Chinese maintainer if this translation is outdated

or if there is a problem with the translation.

Chinese maintainer: zhanjf


Documentation/networking/3c509.txt 的中文翻译

如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文

交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻

译存在问题,请联系中文版维护者。

中文版维护者:

詹杰凡 zhanjf

中文版翻译者:

詹杰凡 zhanjf

中文版校译者:

詹杰凡 zhanjf

以下为正文


1Linux and the 3Com EtherLink III Series Ethercards (driver v1.18c and higher)

2—————————————————————————-

3

4This file contains the instructions and caveats for v1.18c and higher versions

5of the 3c509 driver. You should not use the driver without reading this file.

6

7release 1.0

828 February 2002

9Current maintainer (corrections to):

10  David Ruggiero

11

12—————————————————————————-

13


此文件包含3c509驱动v1.18c以及更高版本的说明和注意事项。没有阅读该文件不得使用该驱动。

1.0版本

2002.02.28

目前维护者(更正):David Ruggiero


14(0) Introduction

15

16The following are notes and information on using the 3Com EtherLink III series

17ethercards in Linux. These cards are commonly known by the most widely-used

18card’s 3Com model number, 3c509. They are all 10mb/s ISA-bus cards and shouldn’t

19be (but sometimes are) confused with the similarly-numbered PCI-bus “3c905”

20(aka “Vortex” or “Boomerang”) series.  Kernel support for the 3c509 family is

21provided by the module 3c509.c, which has code to support all of the following

22models:

23

24  3c509 (original ISA card)

25  3c509B (later revision of the ISA card; supports full-duplex)

26  3c589 (PCMCIA)

27  3c589B (later revision of the 3c589; supports full-duplex)

28  3c579 (EISA)

29

30Large portions of this documentation were heavily borrowed from the guide

31written the original author of the 3c509 driver, Donald Becker. The master

32copy of that document, which contains notes on older versions of the driver,

33currently resides on Scyld web server: .

34

35

(0)    简介

以下是在Linux上使用3Com EtherLink III series ethercards的笔记和信息。这些网卡是公认的最广泛使用的3Com网卡的型号,3c509。它们都是10MB/s的ISA总线卡,不能(但有时可以)与类似于编号的PCI总线”3c905”(又名"Vortex" 或"Boomerang")系列混淆。内核在3c509.c中支持了3c509系列,代码支持所有下列类型:

3c509 (原ISA网卡)

3c509B (之后修订的ISA网卡 支持全双工)

3c589 (PCMCIA)

3c589B (后来修订的3c589支持全双工)

3c579 (EISA)

本文档的大部分文字从3c509驱动的原作者Donald Becker所著指南中大量借鉴。作者拷贝了这个文档,文档包含了旧版本驱动的记录,目前驻留在Scyld web server: 、

36(1) Special Driver Features

37

38Overriding card settings

39

40The driver allows boot- or load-time overriding of the card’s detected IOADDR,

41IRQ, and transceiver settings, although this capability shouldn’t generally be

42needed except to enable full-duplex mode (see below). An example of the syntax

43for LILO parameters for doing this:

44

45    ether=10,0x310,3,0x3c509,eth0

46

47This configures the first found 3c509 card for IRQ 10, base I/O 0x310, and

48transceiver type 3 (10base2). The flag “0x3c509” must be set to avoid conflicts

49with other card types when overriding the I/O address. When the driver is

50loaded as a module, only the IRQ may be overridden. For example,

51setting two cards to IRQ10 and IRQ11 is done by using the irq module

52option:

53

54   options 3c509 irq=10,11

55

56

(1)    特殊的驱动程序功能

覆盖卡设置

当检测到IOADDR,IRQ和收发器设置时,该驱动允许在启动或者加载时覆盖,即使这种功能不用改被普遍需求,除了启用全双工模式(见下文)。举个例子(这样做LILO的参数的语法):

ether=10,0x310,3,0x3c509,eth0

该配置首次找到3c509网卡的IRQ 10, base I/O 0x310, 还有transceiver type 3 (10base2)。标志”0x3c509”必须设置,以避免当覆盖I/O地址时与其他类型网卡发生冲突。当驱动程序被加载为一个模块时,只有IRQ能被覆盖。例如,设置IRQ10和IRQ11是通过使用IRQ模式选项:

options 3c509 irq=10,11

57(2) Full-duplex mode

58

59The v1.18c driver added support for the 3c509B’s full-duplex capabilities.

60In order to enable and successfully use full-duplex mode, three conditions

61must be met:

62

63(a) You must have a Etherlink III card model whose hardware supports full-

64duplex operations. Currently, the only members of the 3c509 family that are

65positively known to support full-duplex are the 3c509B (ISA bus) and 3c589B

66(PCMCIA) cards. Cards without the “B” model designation do not support

67full-duplex mode; these include the original 3c509 (no “B”), the original

683c589, the 3c529 (MCA bus), and the 3c579 (EISA bus).

69

70(b) You must be using your card’s 10baseT transceiver (i.e., the RJ-45

71connector), not its AUI (thick-net) or 10base2 (thin-net/coax) interfaces.

72AUI and 10base2 network cabling is physically incapable of full-duplex

73operation.

74

75(c) Most importantly, your 3c509B must be connected to a link partner that is

76itself full-duplex capable. This is almost certainly one of two things: a full-

77duplex-capable  Ethernet switch (not a hub), or a full-duplex-capable NIC on

78another system that’s connected directly to the 3c509B via a crossover cable.

79

80Full-duplex mode can be enabled using ’ethtool'.

81

82/Extremely important caution concerning full-duplex mode/

83Understand that the 3c509B’s hardware’s full-duplex support is much more

84limited than that provide by more modern network interface cards. Although

85at the physical layer of the network it fully supports full-duplex operation,

86the card was designed before the current Ethernet auto-negotiation (N-way)

87spec was written. This means that the 3c509B family ***cannot and will not

88auto-negotiate a full-duplex connection with its link partner under any

89circumstances, no matter how it is initialized***. If the full-duplex mode

90of the 3c509B is enabled, its link partner will very likely need to be

91independently forced into full-duplex mode as well; otherwise various nasty

92failures will occur - at the very least, you’ll see massive numbers of packet

93collisions. This is one of very rare circumstances where disabling auto-

94negotiation and forcing the duplex mode of a network interface card or switch

95would ever be necessary or desirable.

96

97

(2)    全双工模式

V1.18c的驱动程序加入对3c509B’s的支持。为了启用并成功使用全双工模式,必须满足三个条件:

(a)    你必须有一个Etherlink III型号的网卡,其硬件支持全双工操作。目前,3c509家族成员中只有3c509B (ISA bus)和3c589B(PCMCIA) 支持全双工。网卡的“B”模式不支持全双工,这包括原3c509(没有“B”),原3c589,3c529(MCA总线),以及3c579(EISA总线)。

(b)    你必须使用你的网卡的10baseT收发器(比如RJ-45连接器),而不是他的AUI或者10base2接口。AUI和10base2网络布线本身不能进行全双工操作。

(c)     最重要的是,你的3c509B必须连接到一个能胜任全双工的配对网卡。可以肯定这两件事中的一件:有全双工能力的以太网交换机(不是集线器),或者一个有全双工能力的NIC在另一个系统通过交叉线直接连接。

全双工模式能被启用通过使用‘ethtool’。

/注意关于全双工模式非常重要/

理解3c509B的硬件全双工支持有比更现代化的网络接口网卡更多的限制。虽然在网络的物理层完全支持全双工操作,网卡在写下当前的以太网自动协商细则之前被设计。这意味着,3c509B家族在任何情况下不能也不会自动协商一个全双工连接跟它的配对网卡,不管他是如何初始化的。如果3c509的全双工模式被启用,他连接的配对网卡会很可能需要独立被迫进入全双工模式,否则各种讨厌的失败会发生,最起码,你会看到大量的数字包出现冲突。这是一个非常罕见的环境下,禁止自动协商和迫使一个网络借口卡或者交换机的双工模式,这是必要和值得的。

98(3) Available Transceiver Types

99

100For versions of the driver v1.18c and above, the available transceiver types are:

101

1020  transceiver type from EEPROM config (normally 10baseT); force half-duplex

1031  AUI (thick-net / DB15 connector)

1042  (undefined)

1053  10base2 (thin-net == coax / BNC connector)

1064  10baseT (RJ-45 connector); force half-duplex mode

1078  transceiver type and duplex mode taken from card’s EEPROM config settings

10812 10baseT (RJ-45 connector); force full-duplex mode

109

110Prior to driver version 1.18c, only transceiver codes 0-4 were supported. Note

111that the new transceiver codes 8 and 12 are the only ones that will enable

112full-duplex mode, no matter what the card’s detected EEPROM settings might be.

113This insured that merely upgrading the driver from an earlier version would

114never automatically enable full-duplex mode in an existing installation;

115it must always be explicitly enabled via one of these code in order to be

116activated.

117

118The transceiver type can be changed using ’ethtool'.

119

120

(3)    可供收发器类型

V1.18c及以上驱动程序的版本,可供收发器类型是:

0       收发器类型从EEPROM配置,强制半双工

1       AUI

2       未定义

3       10base2

4       10baseT,强制半双工模式

8       收发器类型和半双工模式获取来自EEPROM配置的设置

12  10baseT,强制全双工模式

在v1.18c版本以前,只有收发器编码在0-4之间被支持。注意新的收发器编码8和12是唯一的能够全双工的模式,无论检测到EEPROM设置的是什么。这确保了在现有的安装下仅仅从更早的版本升级的驱动程序不会自动启用全双工模式,这必须总是明确启用通过代码之一激活。

收发器类型可以被改变通过使用‘ethtool’。

121(4a) Interpretation of error messages and common problems

122

123Error Messages

124

125eth0: Infinite loop in interrupt, status 2011.

126These are “mostly harmless” message indicating that the driver had too much

127work during that interrupt cycle. With a status of 0x2011 you are receiving

128packets faster than they can be removed from the card. This should be rare

129or impossible in normal operation. Possible causes of this error report are:

130

131   - a “green” mode enabled that slows the processor down when there is no

132     keyboard activity.

133

134   - some other device or device driver hogging the bus or disabling interrupts.

135     Check /proc/interrupts for excessive interrupt counts. The timer tick

136     interrupt should always be incrementing faster than the others.

137

138No received packets

139If a 3c509, 3c562 or 3c589 can successfully transmit packets, but never

140receives packets (as reported by /proc/net/dev or ‘ifconfig’) you likely

141have an interrupt line problem. Check /proc/interrupts to verify that the

142card is actually generating interrupts. If the interrupt count is not

143increasing you likely have a physical conflict with two devices trying to

144use the same ISA IRQ line. The common conflict is with a sound card on IRQ10

145or IRQ5, and the easiest solution is to move the 3c509 to a different

146interrupt line. If the device is receiving packets but ‘ping’ doesn’t work,

147you have a routing problem.

148

149Tx Carrier Errors Reported in /proc/net/dev

150If an EtherLink III appears to transmit packets, but the “Tx carrier errors”

151field in /proc/net/dev increments as quickly as the Tx packet count, you

152likely have an unterminated network or the incorrect media transceiver selected.

153

1543c509B card is not detected on machines with an ISA PnP BIOS.

155While the updated driver works with most PnP BIOS programs, it does not work

156with all. This can be fixed by disabling PnP support using the 3Com-supplied

157setup program.

158

1593c509 card is not detected on overclocked machines

160Increase the delay time in id_read_eeprom() from the current value, 500,

161to an absurdly high value, such as 5000.

162

163

(4a) 错误消息和常见问题的解释

错误消息

eth0:无线循环中断,状态2011。

这些都是“基本无害”的消息,表明驱动程序必须做更多的工作在中断周期内。在0x2011状态下,你接收包比他们能够从网卡上移除更快。在正常操作下,这应该是罕见的或者不可能的。报告这个错误的原因可能是:

-“绿色”模式启用减缓了处理器速度当没有键盘活动时。

  • 一些其它设备或者设备驱动程序占用总线或者禁止中断。检查/proc/interrupts中断计数超标。计时器中断应该始终增长速度比其他快。

没有收到报文

如果3c509,3c562或者3c589能成功传输报文,但是从来不接收报文,很可能有一个中断行的问题。检查 /proc/interrupts,以确认网卡实际上是产生了中断。如果中断技术不增长,可能在两个设备之间试图去使用同一个ISAIRQ线发生物理冲突。常见的冲突是声卡在IRQ10或者IRQ5上,最简单的解决方法是去移动3c509到不同的中断行。如果设备正在接收报文但是不能够’ping’通,说明出现路由的问题。

Tx载体错误的报告在/proc/net/dev中

如果一个EtherLink III出现传输报文,但是出现"Tx carrier errors"在/proc/net/dev中Tx报文计数尽快增长,这可能出现一个未终止网络或者不正确的媒体收发器选项。

3c509B网卡不能检测ISA PnP BIOS的机器。虽然更新驱动程序适用于大多数PnP BIOS程序,但这不是总是行得通的。这可以通过禁用PnP提供使用3Com-supplied安装程序来解决。

3c509网卡不能检测超频机器。增加延迟时间在id_read_eeprom()从当前的值,500,一个过高的值,比如5000。

164(4b) Decoding Status and Error Messages

165

166The bits in the main status register are:

167

168value   description

1690x01    Interrupt latch

1700x02    Tx overrun, or Rx underrun

1710x04    Tx complete

1720x08    Tx FIFO room available

1730x10    A complete Rx packet has arrived

1740x20    A Rx packet has started to arrive

1750x40    The driver has requested an interrupt

1760x80    Statistics counter nearly full

177

178The bits in the transmit (Tx) status word are:

179

180value   description

1810x02    Out-of-window collision.

1820x04    Status stack overflow (normally impossible).

1830x08    16 collisions.

1840x10    Tx underrun (not enough PCI bus bandwidth).

1850x20    Tx jabber.

1860x40    Tx interrupt requested.

1870x80    Status is valid (this should always be set).

188

189

190When a transmit error occurs the driver produces a status message such as

191

192   eth0: Transmit error, Tx status register 82

193

194The two values typically seen here are:

195

1960x82

197Out of window collision. This typically occurs when some other Ethernet

198host is incorrectly set to full duplex on a half duplex network.

199

2000x88

20116 collisions. This typically occurs when the network is exceptionally busy

202or when another host doesn’t correctly back off after a collision. If this

203error is mixed with 0x82 errors it is the result of a host incorrectly set

204to full duplex (see above).

205

206Both of these errors are the result of network problems that should be

207corrected. They do not represent driver malfunction.

208

209

(4b)解码状态和错误信息

在主状态寄存器中的位是:

值                        描述

0x01    冲断锁存

0x02    Tx负载,或者Rx欠载

0x04    Tx完成

0x08    Tx的FIFO队列可用

0x10    一个完整的Rx报文到达

0x20    一个Rx报文开始到达

0x40    驱动程序请求中断

0x80    统计计数器几乎满了

在传输状态字的位是:

值                        描述

0x02    窗口碰撞

0x04    状态栈溢出

0x08    16碰撞

0x10    Tx欠载

0x20    Tx不清楚

0x40    Tx中断请求

0x80    状态有效

当传输错误发生时,驱动程序产生一个状态消息,如

eth0:传输错误,Tx状态寄存器82

通常可以看到这两个值:

0x82

窗口碰撞。这通常发生在一些其它的以太网主机没有正确设置为全双工在半双工网络上。

0x88

16碰撞。这通常发生在网络非常繁忙或者发生碰撞后其它主机没有正确的后退。如果这个错误混合着0x82错误,原因是一个主机没有正确地设置全双工。

所有的由于上述错误引起的网络问题应该都可以解决。他们并不代表驱动程序故障。

210(5) Revision history (this file)

211

21228Feb02 v1.0  DR   New; major portions based on Becker original 3c509 docs

213

(5) 修正历史

2002.02.28 v1.0 DR

主要部分是基于Becker原来的3c509文档。