ANA6911A-TXC 10base2 driver modification

Julian Highfield J.C.Highfield@lboro.ac.uk
Fri Aug 14 14:38:00 1998


Donald Becker wrote:
> The options=11 setting should never be needed, unless the card mistakenly
> didn't list the MII transceiver in the EEPROM media table.  But I have seen
> the many reports, so read the "should" above as "in a properly working driver".

I'll be glad to try a few experiments if you have some suggestions of what 
to look for. I can live with needing to set the options value but I would
rather not have to do so. It seems too inelegant :-)
 
> __10base2__
> Unlike media with link beat (10baseT/100baseTx/100VG/fiber), it's hard to
> reliably detect connected 10base2 and AUI media.

I noticed - my 10base2 test setup seemed broken unless I made sure there
was traffic on the thin ethernet segment by running ping from the other
machine.

> in loopback mode to see if the transceiver exists, but...  Anyway, you get
> the idea: a bunch of complexity, the interface offline for many seconds, and
> all for unreliable detection of a media rarely used by the inexperienced.

I always wondered how you'd tell whether a 10base2 interface was in use
if the network was silent. I guess quite often you don't :-(

> > When connecting as 10base2 and insmod'ing the driver I get a few ping
> > packets through the interface, it fails, switches to 10baseT, fails,
> > switches back to 10base2 and then works OK. 10baseT/100baseTX just
> > works once insmod'ed.
> 
> Ahhh, an important clue.

I'm glad that means something to someone!

I think this was the output from insmod'ing the driver with options=1
and the card connected to 10base2. Once that worked OK (10base2 -> 10baseT
-> 10base2) I unplugged the 10base2 and plugged in a 10baseT connection:


Aug 14 17:09:14 scully kernel: tulip.c:v0.89K 8/8/98 
becker@cesdis.gsfc.nasa.gov
Aug 14 17:09:14 scully kernel: eth0: Digital DS21143 Tulip at 0xec80, 00 00 d1 
1b 12 24, IRQ 9.
Aug 14 17:09:14 scully kernel: eth0:  EEPROM default media type Autosense.
Aug 14 17:09:14 scully kernel: eth0:  MII interface PHY 0, setup/reset 
sequences
 2/0 long, capabilities 00 00.
Aug 14 17:09:14 scully kernel: eth0:  Index #0 - Media MII (#11) described by 
a 21142 MII PHY (3) block.
Aug 14 17:09:14 scully kernel: eth0:  Index #1 - Media 10base2 (#1) described 
by
 a 21142 Serial PHY (2) block.
Aug 14 17:09:14 scully kernel: eth0: Checking for MII transceivers...
Aug 14 17:09:14 scully kernel: eth0:  MII transceiver found at MDIO address 1, 
config 3100 status 7849.
Aug 14 17:09:16 scully kernel: eth0: Using user-specified media 10base2.
Aug 14 17:09:16 scully kernel: eth0: 21143 non-MII 10base2 transceiver control 
0009/0705/0006.
Aug 14 17:09:21 scully kernel: eth0: 21143 negotiation status 000001c2, 
10base2.
Aug 14 17:09:21 scully kernel: eth0: 21143 negotiation failed, status 000001c2.
Aug 14 17:09:21 scully kernel: eth0: Testing new 21143 media 10baseT.
Aug 14 17:10:21 scully kernel: eth0: 21143 negotiation status 000021c6, 
10baseT.
Aug 14 17:10:21 scully kernel: eth0: 21143 negotiation failed, status 000021c6.
Aug 14 17:10:21 scully kernel: HACK: 10base2 port
Aug 14 17:10:21 scully kernel: eth0: Testing new 21143 media 10base2.
Aug 14 17:10:21 scully kernel: eth0: 21143 link change, CSR5 = f0268010.
Aug 14 17:10:21 scully kernel: eth0: 21143 link status interrupt 00000002, 
CSR5 f0260000.
Aug 14 17:10:21 scully kernel: eth0: 21143 10mpbs sensed media.


Running OK on 10base2, now change the connection to 10baseT...


Aug 14 17:11:21 scully kernel: eth0: 21143 negotiation status 000001c2, 
10baseT.
Aug 14 17:11:21 scully kernel: eth0: 21143 negotiation failed, status 000001c2.
Aug 14 17:11:21 scully kernel: eth0: Testing new 21143 media 10baseT.
Aug 14 17:11:21 scully kernel: eth0: The transmitter stopped!  CSR5 is 
f0068002,
 CSR6 b2420002.
Aug 14 17:12:21 scully kernel: eth0: 21143 negotiation status 000020c6, 
10baseT.
Aug 14 17:12:21 scully kernel: eth0: 21143 negotiation failed, status 000020c6.
Aug 14 17:12:21 scully kernel: eth0: Testing new 21143 media 100baseTx.
Aug 14 17:13:21 scully kernel: eth0: 21143 negotiation status 000000c6, 
100baseTx.
Aug 14 17:13:21 scully kernel: eth0: The transmitter stopped!  CSR5 is 
f0008102,
 CSR6 b2420200.
Aug 14 17:14:21 scully kernel: eth0: 21143 negotiation status 000020c6, 
100baseTx.
Aug 14 17:14:21 scully kernel: eth0: The transmitter stopped!  CSR5 is 
f0008102,
 CSR6 b2420200.

I think that was also the pattern you get with a 10baseT connection and 
the default options=0, but it's been a couple of days since I last tried 
that.

That driver also had my transmitter restart hack - which definitely 
helped when I was running a hacked 0.89H and had lots of "The transmitter 
stopped!" messages:

2317,2318d2295
<                               /*** Page 4-35 of the 21143 HRM. ***/
<                               outl(0, ioaddr + CSR1);

Regards,
        Julian.