[tulip] tulip driver in kernel 2.4.18 - reversed pci

Donald Becker becker@scyld.com
Wed Dec 18 13:01:18 2002


On Wed, 18 Dec 2002, Chris Voelz wrote:

> I own an adaptec ANA nic, which works quite fine.
> Since the BIOS of my PC is an old broken one, the pci numbering is somehow
> queer. I have read about that on the list but did not find any suitable
> sulution for using the tulip driver with kernel 2.4.18.
> In kernel 2.2.20 the tulip driver had the option to reverse the pci
> numbering - is there any comparable option in the new tulip driver?
> i still want oto use this nice card...

There are two things that need to be done to work around the BIOS bug
that shows up with devices behind a plugged-in bus bridge (pretty much
only four port NICs):
  - The driver must use the IRQ of the first interface for all four NICs.
  - Something must provide the option of reversing the scan, in case some
    part of the system changed the scan order and NIC #1 (with the
    only correct IRQ) is found as NIC #4.
The extra issue is
  - Many quad port NIC only have a configuration EEPROM on the first NIC
    (This is actually good: it's a trigger to break the PCI
    single-device abstraction layer and we do the IRQ fix-up when we do
    the configuration fix-up.) 

My driver releases unconditionally copy the IRQ when compiled for x86
(only!).  They used to have a module option to reverse the scan order
(reverse_probe=1), but that is now ignored.

The kernel has had various very confused approaches, apparently because
some people don't understand the bug, or even believe that it exists.

A better solution is to fix this up in a generic PCI quirks section,
and always provide the driver with the correct IRQ.  That would handle
other types of cards with bus bridges.  But since
  - pretty much only quad Tulip cards exist,
  - few or no existing kernels handle the problem,
  - and I'm the one that gets the "it's broken" blame
this will be continued to be fixed up in my tulip driver releases.

-- 
Donald Becker				becker@scyld.com
Scyld Computing Corporation		http://www.scyld.com
410 Severn Ave. Suite 210		Scyld Beowulf cluster system
Annapolis MD 21403			410-990-9993