[vortex] 3C905CX, 2.2.18, Dell Dimension 4100 (P933) Receive Failure Fix / Inquiry

Donald Becker becker@scyld.com
Wed, 17 Jan 2001 00:36:27 -0500 (EST)


On Tue, 16 Jan 2001, Samuel Madden wrote:

> However, in reading through these posts it became clear that the driver
> is extremely sensistive to various timer-loops in the code, especially with
> newer drivers.  It also struck me that for-loops will stall for different
> amounts of time depending on the processor, while the timeouts of the
> network card probably don't vary with cpu speed.  So, I tried increasing
> the timeouts in vortex_rx and was able to get the driver to work (see diff
> dump below).

You misunderstand the loops.  They are not software timing loops.  They
are PCI transaction counts.  PCI transactions are often the most
appropriate measure.

> I'm wondering:
> 1) why isn't some more precise timing mechanism being used here?

Most of the operations should take zero apparent time.  I check the loop
count for all operations when I write a driver, and it's rare that a
chip actually requires more than one loop iteration.

The loop counts exist to make certain the driver doesn't hang on broken
or missing hardware. 

> 2) what are the performance implications of making the rx timeouts
> 	significantly higher?

Bad.  The kernel is sitting in a very long timing loop.  In some cases
this occurs with many interrupts blocked due to rotating interrupt
priority.

The patches that increase the timing loop counts are for experimental
and verification purposes only.  Please do not submit them for
inclusion in a main-line kernel!

> 3) does anyone have suggestions for what optimal values might be here?  i've
> 	increased them quite a lot and am not really interesting in trying
> 	all the permuations manually.

Not for the CX board -- some aspect of the design appears to have
changed dramatically from the earlier chips.

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