mirror of
https://github.com/freebsd/freebsd-src
synced 2024-11-05 18:22:52 +00:00
A bit of a messy monster.
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
This commit is contained in:
parent
4e5adf5f4a
commit
9385b6d6d7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=61054
1 changed files with 531 additions and 409 deletions
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue