freebsd-skq/sys/dev/ath/ath_hal/ar5211
adrian 703d39b946 Begin adding support to explicitly set the current chainmask.
Right now the only way to set the chainmask is to set the hardware
configured chainmask through capabilities.  This is fine for forcing
the chainmask to be something other than what the hardware is capable
of (eg to reduce TX/RX to one connected antenna) but it does change what
the HAL hardware chainmask configuration is.

For operational mode changes, it (may?) make sense to separately control
the TX/RX chainmask.

Right now it's done as part of ar5416_reset.c - ar5416UpdateChainMasks()
calculates which TX/RX chainmasks to enable based on the operating mode.
(1 for legacy and whatever is supported for 11n operation.)  But doing
this in the HAL is suboptimal - the driver needs to know the currently
configured chainmask in order to correctly enable things for each
TX descriptor.  This is currently done by overriding the chainmask
config in the ar5416 TX routines but this has to disappear - the AR9300
HAL support requires the driver to dynamically set the TX chainmask based
on the TX power and TX rate in order to meet mini-PCIe slot power
requirements.

So:

* Introduce a new HAL method to set the operational chainmask variables;
* Introduce null methods for the previous generation chipsets;
* Add new driver state to record the current chainmask separate from
  the hardware configured chainmask.

Part #2 of this will involve disabling ar5416UpdateChainMasks() and moving
it into the driver; as well as properly programming the TX chainmask
based on the currently configured HAL chainmask.

Tested:

* AR5416, STA mode - both legacy (11a/11bg) and 11n rates - verified
  that AR_SELFGEN_MASK (the chainmask used for self-generated frames like
  ACKs and RTSes) is correct, as well as the TX descriptor contents is
  correct.
2013-02-25 22:42:43 +00:00
..
ar5211_attach.c Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00
ar5211_beacon.c Update the TSF and next-TBTT methods to work for the AR5416 and later NICs. 2011-09-08 01:23:05 +00:00
ar5211_interrupts.c
ar5211_keycache.c
ar5211_misc.c Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00
ar5211_phy.c
ar5211_power.c
ar5211_recv.c Extend the RX HAL API to include the RX queue identifier. 2012-07-09 07:19:11 +00:00
ar5211_reset.c Stop using the hardware register value byte order swapping for now, 2012-04-19 03:26:21 +00:00
ar5211_xmit.c Migrate the ath_hal_filltxdesc() API to take a list of buffer/seglen values. 2012-08-05 10:12:27 +00:00
ar5211.h Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00
ar5211desc.h Remove this include, it isn't needed. 2012-11-18 20:41:46 +00:00
ar5211phy.h
ar5211reg.h Reapply r228785 now it has been tested by Adrian. Also add comments 2011-12-30 02:58:37 +00:00
boss.ini Clean some 'svn:executable' properties in the tree. 2013-01-26 22:08:21 +00:00