freebsd-dev/sys/dev/ath/ath_hal
Adrian Chadd d2a72d673f 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
..
ah_regdomain These two are ath_hal regulatory domain updates from the Atheros 2011-07-20 12:46:58 +00:00
ar5210 Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00
ar5211 Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00
ar5212 Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00
ar5312 Stop using the hardware register value byte order swapping for now, 2012-04-19 03:26:21 +00:00
ar5416 Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00
ar9001 Since the PLL changes aren't in here yet for the AR9130 half/quarter 2012-10-31 21:14:25 +00:00
ar9002 Bring over the basic spectral scan framework code from Qualcomm Atheros. 2013-01-02 00:38:01 +00:00
ar9003 Add AR9380 devid HAL definitions and probe/attach strings. 2012-08-23 03:03:00 +00:00
ah_debug.h Add new HAL configuration features for the updated AR9300 HAL. 2012-11-07 06:23:23 +00:00
ah_decode.h Add a threadid to the ah_decode API. 2012-04-04 20:46:20 +00:00
ah_desc.h Extend the TX descriptor debug printing to be properly aware of 2012-08-19 02:22:16 +00:00
ah_devid.h Add the emulation PCI device id - these days, 0xabcd shows up all over 2012-10-31 20:58:24 +00:00
ah_diagcodes.h Add some more diagnostic codes. 2012-08-24 00:17:39 +00:00
ah_eeprom_9287.c Move this magic check to only occur if no eeprom data is given. 2012-08-26 04:26:49 +00:00
ah_eeprom_9287.h Make sure the extended regdomain word is initialised. 2011-06-28 00:01:55 +00:00
ah_eeprom_v1.c Fix the eeprom set API method to return HAL_STATUS. 2011-05-14 15:12:02 +00:00
ah_eeprom_v1.h Replace Id keyword with FreeBSD keyword and set the svn props correctly. 2010-03-03 17:32:32 +00:00
ah_eeprom_v3.c Fix the eeprom set API method to return HAL_STATUS. 2011-05-14 15:12:02 +00:00
ah_eeprom_v3.h Replace Id keyword with FreeBSD keyword and set the svn props correctly. 2010-03-03 17:32:32 +00:00
ah_eeprom_v4k.c "Upgrade" the AR9285 code to support PCI/ART EEPROM on flash. 2012-04-20 21:56:13 +00:00
ah_eeprom_v4k.h Bring over a pdadc calibration fix from ath9k - unused power detector 2011-04-22 10:57:46 +00:00
ah_eeprom_v14.c Introduce the FRAC_5G EEPROM parameter. 2011-07-30 13:45:12 +00:00
ah_eeprom_v14.h Introduce the FRAC_5G EEPROM parameter. 2011-07-30 13:45:12 +00:00
ah_eeprom.h Bring over some new EEPROM regulatory domain flags. 2012-08-24 01:14:00 +00:00
ah_internal.h Add spectral scan capability. 2012-12-30 06:46:11 +00:00
ah_regdomain.c Add XC900 SKU mapping. 2012-12-07 06:38:30 +00:00
ah_regdomain.h Migrate the regulatory database definitions into separate header files 2011-03-10 03:13:56 +00:00
ah_soc.h Replace Id keyword with FreeBSD keyword and set the svn props correctly. 2010-03-03 17:32:32 +00:00
ah.c Add the initial HAL glue for the spectral analysis support. 2012-12-30 06:48:12 +00:00
ah.h Begin adding support to explicitly set the current chainmask. 2013-02-25 22:42:43 +00:00