21143 chips, I accidentally removed the DC_MII_REDUCED_POLL flag
for all 21143 cards. This caused problems with timer-instigated
TCP retransmits, which happened to occur at the same time as an
MII poll tick on MII-based cards (e.g. D-Link DFE-570TX). Fixed this,
plus made some other cleanups. The autoneg fixes for the non-MII
cards still work. Also tested the PNIC II now that I have one again.
Fix several instances of breakage in RAID-5 revive code.
Tidy up code.
parityops:
Don't attempt to do anything if the plex is degraded or worse.
parityrebuild:
Add comments.
Perform transfers in correct length.
after autoneg so we make sure to set the link state and duplex mode
correctly.
- Make sure to set the 'ignore pause frames' bit on the XMAC.
- Small linewrap fix.
needed to add into ether_input) and finally sorting IFF_RUNNING through
whole driver.
As part of the IFF_RUNNING stuff, we've added an extra flag so callers
can request that runq routines should check IFF_RUNNING before executing.
Remove BPF taps as this is now done by ether_input.
Resurrect multicast code, moving the multicast list stuff to the runq
routine.
Dump ray_promisc_user as all flag changes are now handled by ray_init, and
add a couple of checks to ray_promisc.
In uppparams_user, allow changes before the card is running (need to
fix some breakage with _download here later). In addition, don't
assume that the current n/w parameters are valid - they are only valid
in the runq.
Fix a nasty flag bug - runq_add cleared all the flags on the last command!
Remove the hacks for setting the memory flags - problems were down
to buggy versions of pccardd. For some reason pccardd only dtrt with
the "right" debug_level.
not gone yet.
format_config: print correct text when a volume has a preferred plex.
This is still broken, but not quite as badly.
Reported-by: Phil Regnauld <regnauld@ftf.net>
Change a rather silly comment.
routines from foo_watchdog() because foo_watchdog() is called at
interrupt context, and that's a no-no due to the way the USB stack
is currently set up.
What we do now is call the TX end of frame handler manually to clear
the completed transmission, then check the send queue and send off
any frames that are pending.
Also turned off the interrupt pipe stuff in if_aue, since it appears
to tickle a bug in the USB stack that I haven't found yet.
motherboards that use YMF740's. It has a strange subvendor and subdevice
ID and requires a disturbingly long delay after the ac97 codec init.
Cameron hasn't had this driver tested on another 740 yet, so we don't know
if this is a quirk of all 740's, or if its just something about the codec
that Intel used.
workalike chips (Macronix 98713A/98715 and PNIC II). Timing is somewhat
critical: you need to bring the link as soon as possible after NWAY
is done, and the old one second polling interval was too long. Now
we poll every 10th of a second until NWAY completes (at which point
we return to the 1 second interval again to keep an eye on the link
state).
I tested all the other cards I had on hand to make sure I didn't bust
any of them and they seem to work (including the MII-based 21143 card).
This should fix some autoneg problems with DE500-BA cards and the
built-in 10/100 ethernet on some alpha systems.
(Now before anyone asks why I never noticed this before, the old code
worked just find with the Intel swich I used for testing back in NY.
Apparently not all switches are as picky about the timing.)
It may cause misterious chars appearse in the middle of the scrolled lines.
The bug trigger: enter
grep P_32 /usr/include/*.h
command and see misterious "db.\" filename.
Simple stuff
------------
Split _download up so that the MIB settings are in their own functions.
Made "tx completed but status is ..." a recoverable error
Cut down verbosity of "unloaded" messages
Moved ccs_free and com_runq from intr_ccs to ecf_done and runq_done
to avoid embarasing mistakes and waits.
Merged runq_add and runq_arr into one and called it runq_add
Made RAY_COM_DUMP a real debug called RAY_DCOM
Consistnet debugging around tsleeps.
Use bus_activate_resource for attr/cm mapping, and set the flags
correctly in the allocation routines (needs more hacks to
sys/pccard/pcic.c)
com_malloc is now seperated from the comq initialization. This was
done whilst trying to set automatic variables for the comqs.
Harder Stuff
------------
As part of the IFF_RUNNING fixes, remove the panic in runq if we are
not running.
Change, again, runq_add. This time we don't do any cleaning up
if there were errors. This is so that callers get the chance
to re-try (not that I ever see it being used).
In runq_add, only sleep when there is something to sleep on!
ioctl locking routines, stolen from awi.c but not used
Hardest Stuff
-------------
Dealing with serialing ioctls correctly means that we must QUEUE
changes to IFF_RUNNING and check it in the QUEUED commands, not
in the user commands. Whilst simple to state, it took a few
hours of head scratching to get it right. The realisation was that
I only have to guarantee that sub-commands from a single process
are serialised and "atomic", and that they check the status of the
interface flags when invoked and not when they are queued.
Another way of looking at it, is that the driver's state is stored
in the runq and the IFF_RUNNING flag. These must be changed together.
What this means practically, is that IFF_RUNNING is set after
we have started/joined/associated with a network. And it is
cleared by ray_stop via the runq so that unfinsished commands are
not distrupted.
I still have to fix up promisc, upp/repparams and mcast.
Oh yeah, stop is essentially a noop in that it only
changes IFF_RUNNING
- Get rid of a fiew uselessly `long' variables
and casts to `long'.
- Estimate the PCI clock for all chips, except
C1010 for now (we should do that for each PCI BUS)
- Refine a couple of C1010 errata work-arounds.
- For now, make sure AIP generation is disabled
for the C1010-66.
"options COMPAT_OLDPCI". This option already existed, but now also tidies
up the declarations in #include <pci/pci*.h>. It is amazing how much stuff
was using the old pre-FreeBSD 3.x names and going silently undetected.