Subject: Re: PCMCIA NE2000 clones
To: None <port-i386@NetBSD.ORG>
From: Laine Stump <laine@morningstar.SPAM-FREE-OR-DIE.com>
List: port-i386
Date: 04/29/1998 03:08:33
Havard.Eidnes@runit.sintef.no writes:
>
>It is conceivable (as Jason Thorpe answered) that the card is
>sufficiently compatible that it will work after a minor tweak is
>done to the driver. Take a look in /sys/dev/pcmcia/if_ne_pcmcia.c
>and note the section near the top which is #if 0'ed and which starts
>with the comment
> /* the rest of these are stolen from the linux pcnet pcmcia device
> driver. Since I don't know the manfid or cis info strings for
> any of them, they're not compiled in until I do. */
>from searching, I can't seem to find either "New" or "Media" as
>strings, but that doesn't have to mean that it can't work.
>You could compile a kernel with PCMCIAVERBOSE (not sure if that is
>required, although it would probably help) and pop the card in and
>note down both the strings emitted and the product and manufacturer
>IDs. You could then install a new entry in the ne2000devs[] table
>by following the established pattern and check if it can work after
>that modification.
I recently tried doing this with an RPTI EP400 card (which is listed
in the Linux stuff). When I was done, I got the following:
pcmcia0 at pcic0 controller 0 socket 0
pcmcia0: CIS version 2.0 or 2.01
pcmcia0: CIS info: RPTI LTD., EP400, CISV100, \M^T\^D SL
pcmcia0: Manufacturer code 0xffffffff, product 0xffffffff
pcmcia0: function 0: network adapter, ccr addr 100 mask 1
pcmcia0: function 0, config table entry 48: I/O card; irq mask 9e3c; iomask 5, iospace
300-31f; mwait_required rdybsy_active wp_active bvd_active io8 io16 irqpulse
pcmcia0: function 0, config table entry 49: I/O card; irq mask 9e3c; iomask 5, iospace
320-33f; mwait_required rdybsy_active wp_active bvd_active io8 io16 irqpulse
pcmcia0: function 0, config table entry 50: I/O card; irq mask 9e3c; iomask 5, iospace
340-35f; mwait_required rdybsy_active wp_active bvd_active io8 io16 irqpulse
ne2 at pcmcia0 function 0 port 0x340-0x34f port 0x350-0x35f
ne2: enet addr has incorrect vendor code
ne2: (34:30:30 should be 00:80:c8)
Note that 34:30:30 is "400". Hmmm.
Here's the original Linux version:
{ "RPTI EP400",
0x0000, 0x0000, NULL, NULL, 0,
0x0110, { 0x00, 0x40, 0x95 } },
and here's the one I made for NetBSD:
{ "RPTI EP400",
PCMCIA_MANUFACTURER_INVALID, PCMCIA_PRODUCT_INVALID,
"RPTI LTD.", "EP400", 0,
0x0040, { 0x00, 0x80, 0xc8 },
So what did I do wrong?