freebsd kernel with SKQ
Go to file
adrian 0b04a7a29e Overhaul the TXQ locking (again!) as part of some beacon/cabq timing
related issues.

Moving the TX locking under one lock made things easier to progress on
but it had one important side-effect - it increased the latency when
handling CABQ setup when sending beacons.

This commit introduces a bunch of new changes and a few unrelated changs
that are just easier to lump in here.

The aim is to have the CABQ locking separate from other locking.
The CABQ transmit path in the beacon process thus doesn't have to grab
the general TX lock, reducing lock contention/latency and making it
more likely that we'll make the beacon TX timing.

The second half of this commit is the CABQ related setup changes needed
for sane looking EDMA CABQ support.  Right now the EDMA TX code naively
assumes that only one frame (MPDU or A-MPDU) is being pushed into each
FIFO slot.  For the CABQ this isn't true - a whole list of frames is
being pushed in - and thus CABQ handling breaks very quickly.

The aim here is to setup the CABQ list and then push _that list_ to
the hardware for transmission.  I can then extend the EDMA TX code
to stamp that list as being "one" FIFO entry (likely by tagging the
last buffer in that list as "FIFO END") so the EDMA TX completion code
correctly tracks things.

Major:

* Migrate the per-TXQ add/removal locking back to per-TXQ, rather than
  a single lock.

* Leave the software queue side of things under the ATH_TX_LOCK lock,
  (continuing) to serialise things as they are.

* Add a new function which is called whenever there's a beacon miss,
  to print out some debugging.  This is primarily designed to help
  me figure out if the beacon miss events are due to a noisy environment,
  issues with the PHY/MAC, or other.

* Move the CABQ setup/enable to occur _after_ all the VAPs have been
  looked at.  This means that for multiple VAPS in bursted mode, the
  CABQ gets primed once all VAPs are checked, rather than being primed
  on the first VAP and then having frames appended after this.

Minor:

* Add a (disabled) twiddle to let me enable/disable cabq traffic.
  It's primarily there to let me easily debug what's going on with beacon
  and CABQ setup/traffic; there's some DMA engine hangs which I'm finally
  trying to trace down.

* Clear bf_next when flushing frames; it should quieten some warnings
  that show up when a node goes away.

Tested:

* AR9280, STA/hostap, up to 4 vaps (staggered)
* AR5416, STA/hostap, up to 4 vaps (staggered)

TODO:

* (Lots) more AR9380 and later testing, as I may have missed something here.
* Leverage this to fix CABQ hanling for AR9380 and later chips.
* Force bursted beaconing on the chips that default to staggered beacons and
  ensure the CABQ stuff is all sane (eg, the MORE bits that aren't being
  correctly set when chaining descriptors.)
2013-03-24 00:03:12 +00:00
bin Fix compiling ed w/ WITHOUT_ED_CRYPTO... These variables aren't 2013-03-23 19:04:57 +00:00
cddl dtrace: ensure that we can always catch a process (e.g. when -c is used) 2013-03-23 08:57:54 +00:00
contrib Merge bugfix from vendor master branch: 2013-03-23 21:34:10 +00:00
crypto Revert r247892 now that this has been fixed upstream. 2013-03-23 14:52:31 +00:00
etc rc.d/sysctl: Fix error messages about unknown OIDs. 2013-03-22 20:12:25 +00:00
games Remove a reference to instant-server which has been removed from the 2013-03-21 12:42:25 +00:00
gnu As it's done for libstdc++, use SJLJ-based exceptions on arm when we're not 2013-03-22 21:50:32 +00:00
include Add an implementation of open_memstream() and open_wmemstream(). These 2013-02-27 19:50:46 +00:00
kerberos5 Add -lheimntlm to LDADD directly. 2013-02-11 09:45:24 +00:00
lib libdwarf: anonymous types are expected to have empty type names... 2013-03-23 08:50:56 +00:00
libexec Map libraries linked with -Ttext-segment=base_addr at base_addr. 2013-02-27 09:34:09 +00:00
release the NO_PAM option has been finally removed in favor of WITHOUT_PAM. 2013-02-18 02:08:41 +00:00
rescue WiP merge of libzfs_core (MFV r238590, r238592) 2013-03-05 08:09:53 +00:00
sbin Revert 248634 and 248643 (e.g., restoring 248625 and 248639). 2013-03-23 20:00:02 +00:00
secure Upgrade to OpenSSH 6.2p1. The most important new features are support 2013-03-22 17:55:38 +00:00
share Extend taskqueue(9) to enable per-taskqueue callbacks. 2013-03-23 15:11:53 +00:00
sys Overhaul the TXQ locking (again!) as part of some beacon/cabq timing 2013-03-24 00:03:12 +00:00
tools More indentation fixes. 2013-03-23 23:27:16 +00:00
usr.bin Make systat -vmstat to use suffixes to display big floating point numbers 2013-03-23 13:11:54 +00:00
usr.sbin Replace deprecated (or remove obsolete) libarchive 2.8 functions 2013-03-22 10:17:42 +00:00
COPYRIGHT Happy New Year 2013! 2012-12-31 11:22:55 +00:00
LOCKS Test commit to make sure commit mail works after moving the server. 2012-12-29 16:03:23 +00:00
MAINTAINERS MAINTAINERS: Document my maintainership of sh(1). 2013-03-03 15:02:56 +00:00
Makefile Add the buildLINT convenience target, handy for build automation. 2012-11-03 20:43:12 +00:00
Makefile.inc1 libzfs_core depends on libnvpair, explicitly say this in Makefile.inc1. 2013-03-05 22:51:11 +00:00
ObsoleteFiles.inc Belatedly remove the vinum(4) manual page. The vinum 2013-03-16 08:51:47 +00:00
README
UPDATING Merge r247814 from x86 modulo whitespace bug: 2013-03-08 13:11:45 +00:00

This is the top level of the FreeBSD source directory.  This file
was last revised on:
$FreeBSD$

For copyright information, please see the file COPYRIGHT in this
directory (additional copyright information also exists for some
sources in this tree - please see the specific source directories for
more information).

The Makefile in this directory supports a number of targets for
building components (or all) of the FreeBSD source tree, the most
commonly used one being ``world'', which rebuilds and installs
everything in the FreeBSD system from the source tree except the
kernel, the kernel-modules and the contents of /etc.  The ``world''
target should only be used in cases where the source tree has not
changed from the currently running version.  See:
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/makeworld.html
for more information, including setting make(1) variables.

The ``buildkernel'' and ``installkernel'' targets build and install
the kernel and the modules (see below).  Please see the top of
the Makefile in this directory for more information on the
standard build targets and compile-time flags.

Building a kernel is a somewhat more involved process, documentation
for which can be found at:
   http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig.html
And in the config(8) man page.
Note: If you want to build and install the kernel with the
``buildkernel'' and ``installkernel'' targets, you might need to build
world before.  More information is available in the handbook.

The sample kernel configuration files reside in the sys/<arch>/conf
sub-directory (assuming that you've installed the kernel sources), the
file named GENERIC being the one used to build your initial installation
kernel.  The file NOTES contains entries and documentation for all possible
devices, not just those commonly used.  It is the successor of the ancient
LINT file, but in contrast to LINT, it is not buildable as a kernel but a
pure reference and documentation file.


Source Roadmap:
---------------
bin		System/user commands.

cddl		Various commands and libraries under the Common Development
		and Distribution License.

contrib		Packages contributed by 3rd parties.

crypto		Cryptography stuff (see crypto/README).

etc		Template files for /etc.

games		Amusements.

gnu		Various commands and libraries under the GNU Public License.
		Please see gnu/COPYING* for more information.

include		System include files.

kerberos5	Kerberos5 (Heimdal) package.

lib		System libraries.

libexec		System daemons.

release		Release building Makefile & associated tools.

rescue		Build system for statically linked /rescue utilities.

sbin		System commands.

secure		Cryptographic libraries and commands.

share		Shared resources.

sys		Kernel sources.

tools		Utilities for regression testing and miscellaneous tasks.

usr.bin		User commands.

usr.sbin	System administration commands.


For information on synchronizing your source tree with one or more of
the FreeBSD Project's development branches, please see:

  http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/synching.html