Subject: Re: 3Com 3c900 and 3c590
To: Tom Trebisky <tom@kofa.as.arizona.edu>
From: Curt Sampson <curt@portal.ca>
List: port-i386
Date: 10/10/1996 23:58:49
On Thu, 10 Oct 1996, Tom Trebisky wrote:

> I just got my package from 3Com yesterday -- the TR manuals for the
> 3c509 and the 3c590.  It sounds like we are going to be attacking
> this same problem, so please keep in touch!  I will certainly pass
> along anything I manage to get worked out.

Right-o. I'll be posting notices of stuff available for testing
and the like to current-users. I think the next step is to instrument
the driver and see what's happening where. Performance in 100 Mbps
is abysmal in some circumstances.

> I heard this as a maybe -- that is that the Rev B of the 3c900 will
> drop the PIO mode which provides backwards compatibility with the
> 3c590.

Yes, I read this too.

> There is a kindof unpleasant gotcha in all of this.  The Rev A of
> the 3c900 has some kind of bug doing receive DMA at 10 mbps, so you
> really need to run it in PIO mode...

Are you sure this isn't item number 3 in the `All Adapters' section
of the Appendix in your 3c59x documentation (on the very last page
in my booklet)? I should think they'll get this fixed up in the
newer versions of the card. Since it looks to be easiest to set up
a separate driver (eb?) for the DMA mode, you could just continue
to use the old PIO mode driver on the older cards. We'd just have
to add a flag to ask ep to recognise the 3c900s, and leave the eb
driver out of the kernel, or something like that.

> Or is there a quick patch to the
> 3c590 driver that will just let me run my 3c900 is PIO mode or some
> such?  I got the impression reading this list that people were doing
> that, but didn't see any code in NetBSD-current on netbsd.org.
> I am actually running 1.2 on my machine.

At this point you have to run it in PIO mode; there is no bus-master
driver available. Use the standard ep driver. You need to patch
/sys/dev/pci/if_ep_pci.c to recognise the adapter, and /sys/dev/ic/elink3.c
and elink3var.h to fix a bug (well, really a `feature' the original
authors didn't know was going to be added) in the code. There's
still something wrong with the driver, but that fixes the lock-up
problem.

(If you need copies of any of these patches, send me e-mail.)

cjs

Curt Sampson    curt@portal.ca		Info at http://www.portal.ca/
Internet Portal Services, Inc.	
Vancouver, BC   (604) 257-9400		De gustibus, aut bene aut nihil.