Skip site navigation (1)Skip section navigation (2)
Date:      12 Feb 2001 21:30:20 +0100
From:      Dag-Erling Smorgrav <des@ofug.org>
To:        mobile@freebsd.org
Cc:        wpaul@freebsd.org
Subject:   dc0 problems
Message-ID:  <xzplmrbprtv.fsf@flood.ping.uio.no>

next in thread | raw e-mail | index | archive | help
I have two IBM EtherJet 10/100 Cardbus cards (Xircom X3201), one with
external dongle, the other with built-in jack (the outside end of the
card is twice as thick as the inside end).

The one with the external dongle works fine. The one with the built-in
jack generates lots of "TX underrun" messages (up to several hundred a
minute):

Feb  9 20:30:58 aes /boot/kernel/kernel: dc0: TX underrun -- using store and forward mode
Feb  9 20:33:58 aes /boot/kernel/kernel: dc0: TX underrun -- using store and forward mode
Feb  9 20:35:28 aes last message repeated 30 times
Feb  9 20:45:28 aes last message repeated 205 times
Feb  9 20:54:59 aes last message repeated 132 times
Feb  9 21:05:29 aes last message repeated 73 times
Feb  9 21:09:59 aes last message repeated 25 times
Feb  9 21:10:29 aes /boot/kernel/kernel: dc0: TX underrun -- using store and forward mode
Feb  9 21:10:29 aes last message repeated 4 times
Feb  9 21:12:29 aes last message repeated 52 times
Feb  9 21:12:59 aes /boot/kernel/kernel: dc0: TX underrun -- using store and forward mode
Feb  9 21:38:30 aes /boot/kernel/kernel: dc0: TX underrun -- using store and forward mode
Feb  9 21:39:30 aes last message repeated 35 times

Here's a diff of the probe messages for the two cards; where they
differ, the - lines are from the one that works and the + lines from
the one that doesn't. Note that the production dates and MAC addresses
are (unsurprisingly) different; other than that, the only differences
are a few bytes in some of the unkown tuples (one of which seems to
contain the lower 24 bits of the MAC address).

--- dc0-works   Mon Feb 12 21:17:55 2001
+++ dc0-doesnt-work     Mon Feb 12 21:18:08 2001
@@ -1,33 +1,33 @@
 cardbus0: Detaching card: no cards to detach!
 pccbb0: pccbb_power: CARD_VCC_0V and CARD_VPP_0V [44]
-pccbb1: card inserted: event=0x00000000, state=30000920
+pccbb1: card inserted: event=0x00000009, state=30000920
 pccbb1: pccbb_power: CARD_VCC_0V and CARD_VPP_0V [44]
 pccbb1: pccbb_power: CARD_VCC_3V and CARD_VPP_VCC [11]
 TUPLE: LINKTARGET [3]: 43 49 53
 Product version: 5.0
 Product name: IBM | 10/100 EtherJet CardBus | IBMC-10/100 | 1.04 |
-TUPLE: Unknown(0x88) [4]: 8d cb 90 00
-TUPLE: Unknown(0x8a) [12]: 4a 31 35 35 31 39 30 43 42 38 44 00
-TUPLE: Unknown(0x8b) [4]: 00 00 00 00
+TUPLE: Unknown(0x88) [4]: db 4b 25 00
+TUPLE: Unknown(0x8a) [12]: 4a 31 35 35 31 32 35 34 42 44 42 00
+TUPLE: Unknown(0x8b) [4]: 01 00 00 00
 Manufacturer ID: a400130181
-TUPLE: DATE [4]: ef 52 b9 26
+TUPLE: DATE [4]: a2 4a 39 29
 Functions: Network Adaptor, Multi-Functioned
-Function Extension: 040600062990cb8d
+Function Extension: 0406000629254bdb
 Function Extension: 0102
 Function Extension: 0280969800
 Function Extension: 0200e1f505
 Function Extension: 0301
 Function Extension: 0303
 Function Extension: 0501
 TUPLE: DEVICE_OC [4]: 02 4f 02 ff
 cardbus1: Opening BAR: type=IO, bar=10, len=0080
 cardbus1: Opening BAR: type=MEM, bar=14, len=0080
 cardbus1: Opening BAR: type=MEM, bar=18, len=0100
 cardbus1: Invalid BAR number: 27(06)
 TUPLE: CONFIG_CB [7]: 03 02 03 01 00 00 ff
 TUPLE: CFTABLE_ENTRY_CB [8]: 41 b0 b0 bc 8e 0e fb 04
 TUPLE: CFTABLE_ENTRY_CB [9]: 02 b8 02 b0 bc 8e 1c fb 04
 TUPLE: NO_LINK [0]:
 CIS reading done
 dc0: <Xircom X3201 10/100BaseTX> port 0x3000-0x307f mem 0x44004000-0x44007fff,0x44000800-0x44000fff,0x44000000-0x440007ff irq 11 at device 0.0 on cardbus1
-dc0: Ethernet address: 00:06:29:90:cb:8d
+dc0: Ethernet address: 00:06:29:25:4b:db

Bill Paul suggested on IRC to set the DC_TX_STORENFWD flag for X3201
chips, but I haven't tried that yet (I'll post the results when I get
the chance) and it doesn't seem entirely fair since the other card
works fine without it (including autonegotiation; I've used it on both
10 and 100 Mbps networks). Here's the patch (watch for whitespace
conflicts due to cut'n'paste):

des@aes /sys/pci% lcvs diff if_dc.c
Index: if_dc.c
===================================================================
RCS file: /home/ncvs/src/sys/pci/if_dc.c,v
retrieving revision 1.44
diff -u -r1.44 if_dc.c
--- if_dc.c     2001/01/20 00:07:49     1.44
+++ if_dc.c     2001/02/12 20:00:07
@@ -1927,6 +1927,7 @@
        case DC_DEVICEID_X3201:
                sc->dc_type = DC_TYPE_XIRCOM;
                sc->dc_flags |= DC_TX_INTR_ALWAYS | DC_TX_COALESCE;
+               sc->dc_flags |= DC_TX_STORENFWD;
                /*
                 * We don't actually need to coalesce, but we're doing
                 * it to obtain a double word aligned buffer.

If I get the dongle for the other card back (I inadvertantly left it
at a customer's after a meeting) I may be able to send the dongle-less
card to someone capable of looking into this problem (provided my
employer approves, as the card is not mine).

DES
-- 
Dag-Erling Smorgrav - des@ofug.org


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-mobile" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?xzplmrbprtv.fsf>