#
285830 |
|
23-Jul-2015 |
gjb |
- Copy stable/10@285827 to releng/10.2 in preparation for 10.2-RC1 builds. - Update newvers.sh to reflect RC1. - Update __FreeBSD_version to reflect 10.2. - Update default pkg(8) configuration to use the quarterly branch.[1]
Discussed with: re, portmgr [1] Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
#
256281 |
|
10-Oct-2013 |
gjb |
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation
|
#
251655 |
|
12-Jun-2013 |
adrian |
Migrate the LNA mixing diversity machinery from the AR9285 HAL to the driver.
The AR9485 chip and AR933x SoC both implement LNA diversity. There are a few extra things that need to happen before this can be flipped on for those chips (mostly to do with setting up the different bias values and LNA1/LNA2 RSSI differences) but the first stage is putting this code into the driver layer so it can be reused.
This has the added benefit of making it easier to expose configuration options and diagnostic information via the ioctl API. That's not yet being done but it sure would be nice to do so.
Tested:
* AR9285, with LNA diversity enabled * AR9285, with LNA diversity disabled in EEPROM
|
#
251483 |
|
07-Jun-2013 |
adrian |
Add bluetooth fixes to the AR5416/AR92xx HAL:
* Call the bluetooth setup function during the reset path, so the bluetooth settings are actually initialised. * Call the AR9285 diversity functions during bluetooth setup; so the AR9285 diversity and antenna configuration registers are correctly programmed * Misc debugging info.
Tested:
* AR9285+AR3011 bluetooth combo; this code itself doesn't enable bluetooth coexistence but it's part of what I'm currently using.
|
#
251400 |
|
05-Jun-2013 |
adrian |
Add a new capability flag to announce that the chip implements LNA mixing for the RX path.
This is different to the div comb HAL flag, that says it actually can use this for RX diversity (the "slow" diversity path implemented but disabled in the AR9285 HAL code.)
Tested:
* AR9285, STA operation
|
#
251360 |
|
04-Jun-2013 |
adrian |
Add the combined (mixed) diversity support capability bit for the AR9285/AR9485.
|
#
249131 |
|
05-Apr-2013 |
adrian |
HAL additions to enable MCI Bluetooth coexistence in the AR9300 HAL.
* Add the rest of the missing GPIO output mux types; * Add in a new debug category; * And a new MCI btcoex configuration option in ath_hal.ah_config
Obtained from: Qualcomm Atheros
|
#
247774 |
|
04-Mar-2013 |
adrian |
add a method to set/clear the VMF field in the TX descriptor.
Obtained from: Qualcomm Atheros
|
#
247366 |
|
27-Feb-2013 |
adrian |
Add in the STBC TX/RX capability support into the HAL and driver.
The HAL already included the STBC fields; it just needed to be exposed to the driver and net80211 stack.
This should allow single-stream STBC TX and RX to be negotiated; however the driver and rate control code currently don't do anything with it.
|
#
247286 |
|
25-Feb-2013 |
adrian |
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.
|
#
245281 |
|
11-Jan-2013 |
adrian |
Place-holders for enable/active parameter flags.
|
#
244854 |
|
30-Dec-2012 |
adrian |
Add the initial HAL glue for the spectral analysis support.
* Finish adding the HAL capability to announce whether a NIC supports spectral scan or not; * Add spectral scan methods to the HAL structure; * Add HAL_SPECTRAL_PARAM for configuration of the spectral scan logic.
The capability ID and HAL_SPECTRAL_PARAM struct are from Qualcomm Atheros.
|
#
243840 |
|
03-Dec-2012 |
adrian |
Add and tie in the AR5416 bluetooth coexistence methods into the HAL.
|
#
243743 |
|
01-Dec-2012 |
adrian |
Add a new HAL capability - check and enforce whether the NIC supports enforcing the TXOP and TBTT limits:
* Frames which will overlap with TBTT will not TX; * Frames which will exceed TXOP will be filtered.
This is not enabled by default; it's intended to be enabled by the TDMA code on 802.11n capable chipsets.
|
#
243589 |
|
27-Nov-2012 |
adrian |
Add a note about the magic values here; don't change them.
|
#
243424 |
|
23-Nov-2012 |
adrian |
Implement a HAL method to set a 64 bit TSF value.
TODO: implement it (and test) for the AR5210/AR5211.
|
#
242689 |
|
07-Nov-2012 |
adrian |
Add new HAL configuration features for the updated AR9300 HAL.
|
#
242509 |
|
03-Nov-2012 |
adrian |
HAL API changes!
* introduce a new HAL API method to pull out the TX status descriptor contents.
* Add num_delims to the 11n first aggr method. This isn't used by the driver at the moment so it won't affect anything.
|
#
242407 |
|
31-Oct-2012 |
adrian |
Add in the last random assortment of missing bits for the AR9380 HAL.
Obtained from: Qualcomm Atheros
|
#
240623 |
|
17-Sep-2012 |
adrian |
Rename AH_MIMO_MAX_CHAINS to AH_MAX_CHAINS, for compatibility with internal atheros HAL code.
|
#
239890 |
|
30-Aug-2012 |
adrian |
Migrate the AR9285 diversity configuration LNA configuration to use some HAL definitions rather than local definitions.
The original source (ath9k) pulled this stuff from the QCA driver and removed the HAL_* prefix. I'm just restoring the correct order of things.
Obtained from: Qualcomm Atheros
|
#
239638 |
|
24-Aug-2012 |
adrian |
Implement an API to fetch the default DFS parameters for the given chip.
The only chip this is currently implemented for is the AR5416 HAL family. A follow-up commit will add AR5212 support.
PR: kern/170904
|
#
239635 |
|
24-Aug-2012 |
adrian |
Oops, another copy/paste issue.
|
#
239634 |
|
24-Aug-2012 |
adrian |
Add ath_hal_get_curmode() - this is used by the Osprey HAL.
Obtained from: Qualcomm Atheros
|
#
239632 |
|
24-Aug-2012 |
adrian |
Oops, fix copy/paste silliness.
|
#
239631 |
|
24-Aug-2012 |
adrian |
Add some more capabilities (unused at the present.)
Obtained from: Qualcomm Atheros
|
#
239606 |
|
23-Aug-2012 |
adrian |
Add a placeholder and typedefs for MFP (management frame protection.)
Obtained from: Qualcomm Atheros
|
#
239605 |
|
23-Aug-2012 |
adrian |
Add some more interrupt handling bits.
Obtained from: Qualcomm Atheros
|
#
239289 |
|
15-Aug-2012 |
adrian |
Bump up the rate control table size to incorporate 3 stream entries.
|
#
239053 |
|
05-Aug-2012 |
adrian |
Migrate the 802.11n ath_hal_chaintxdesc() API to use a buffer/segment array, similar to what filltxdesc() uses.
This removes the last reference to ds_data in the TX path outside of debugging statements. These need to be adjusted/fixed.
Tested:
* AR9280 STA/AP with iperf TCP traffic
|
#
239051 |
|
05-Aug-2012 |
adrian |
Migrate the ath_hal_filltxdesc() API to take a list of buffer/seglen values.
The existing API only exposes 'seglen' (the current buffer (segment) length) with the data buffer pointer set in 'ds_data'. This is fine for the legacy DMA engine but it won't work for the EDMA engines.
The EDMA engine has a significantly different TX descriptor layout.
* The legacy DMA engine had a ds_data pointer at the same offset in the descriptor for both TX and RX buffers; * The EDMA engine has no ds_data for RX - the data is DMAed after the descriptor; * The EDMA engine has support for 4 TX buffer/segment pairs in the TX DMA descriptor; * The EDMA TX completion is in a different FIFO, and the driver will 'link' the status completion entry to a QCU by a "QCU ID". I don't know why it's just not filled in by the hardware, alas.
So given that, here are the changes:
* Instead of directly fondling 'ds_data' in ath_desc, change the ath_hal_filltxdesc() to take an array of buffer pointers as well as segment len pointers; * The EDMA TX completion status wants a descriptor and queue id. This (for now) uses bf_state.bfs_txq and will extract the hardware QCU ID from that. * .. and this is ugly and wasteful; it should change to just store the QCU in the bf_state and save 3/7 bytes in the process.
Now, the weird crap:
* The aggregate TX path was using bf_state->bfs_txq for the TXQ, rather than taking a function argument. I've tidied that up. * The multicast queue frames get put on a software TXQ and then that is appended to the hardware CABQ when appropriate. So for now, make sure that bf_state->bfs_txq points at the CABQ when adding frames to the multicast queue. * .. but the multicast queue TX path for now doesn't use the software queue and instead (a) directly sets up the descriptor contents at that point; (b) the frames on the vap->avp_mcastq are then just appended wholesale to the CABQ. So for now, I don't have to worry about making the multicast path work with aggregation or the per-TID software queue. Phew.
What's left to do:
* I need to modify the 11n ath_hal_chaintxdesc() API to do the same. I'll do that in a subsequent commit. * Remove bf_state.bfs_txq entirely and store the QCU as appropriate. * .. then do the runtime "is this going on the right HWQ?" checks using that, rather than comparing pointer values.
Tested on:
* AR9280 STA/AP * AR5416 STA/AP
|
#
238857 |
|
28-Jul-2012 |
adrian |
Commit missing #define from a previous check-in.
The AR9300 and later have an 8-deep TX FIFO for each hardware queue.
|
#
238841 |
|
27-Jul-2012 |
adrian |
Add a STBC TX flag.
Obtained from: Qualcomm Atheros
|
#
238840 |
|
27-Jul-2012 |
adrian |
Add some comments about what the two fields mean.
|
#
238839 |
|
27-Jul-2012 |
adrian |
Introduce a couple more fields in the rate scenario setup as part of (future) TPC support in the AR9300 HAL.
This is effectively a no-op for the moment as (a) TPC isn't really supported, (b) the AR9300 HAL isn't yet public, and (c) the existing HAL code doesn't use these fields.
Obtained from: Qualcomm Atheros
|
#
238838 |
|
27-Jul-2012 |
adrian |
Bring this API in line with what the reference driver and Linux ath9k was doing.
Obtained from: Qualcomm Atheros, Linux ath9k
|
#
238731 |
|
24-Jul-2012 |
adrian |
Add a new HAL method - the AR93xx and later NICs have a separate TX descriptor ring for TX status completion. This API call will pass the allocated buffer details to the HAL.
|
#
238607 |
|
19-Jul-2012 |
adrian |
Break out the TX descriptor link field into HAL methods.
The DMA FIFO chips (AR93xx and later) differ slightly to th elegacy chips:
* The RX DMA descriptors don't have a ds_link field; * The TX DMA descriptors have a ds_link field however at a different offset.
This is a reimplementation based on what the reference driver and ath9k does.
A subsequent commit will enable it in the TX and beacon paths.
Obtained from: Linux ath9k, Qualcomm Atheros
|
#
238349 |
|
10-Jul-2012 |
adrian |
Commit missing flags for the high/low priority (HP/LP) RX queues.
Noticed by: everyone
|
#
238280 |
|
09-Jul-2012 |
adrian |
Introduce the EDMA related HAL capabilities.
Whilst here, fix a typo in a previous commit.
Obtained from: Qualcomm Atheros
|
#
238278 |
|
09-Jul-2012 |
adrian |
Extend the RX HAL API to include the RX queue identifier.
The AR93xx and later chips support two RX FIFO queues - a high and low priority queue.
For legacy chips, just assume the queues are high priority.
This is inspired by the reference driver but is a reimplementation of the API and code.
|
#
237957 |
|
02-Jul-2012 |
adrian |
.. And fix another typo. Grr.
|
#
237956 |
|
02-Jul-2012 |
adrian |
Fix another typo.
|
#
237955 |
|
02-Jul-2012 |
adrian |
Fix typo.
|
#
237953 |
|
02-Jul-2012 |
adrian |
Bring over some further HAL capabilities from the Atheros HAL, as well as an EDMA check function.
For the AR9003 and later NICs, different TX/RX DMA and descriptor handling code will be conditional on the EDMA check.
Obtained from: Qualcomm Atheros
|
#
237874 |
|
01-Jul-2012 |
adrian |
Add in some further changes from the AR9300 HAL:
* Add a new ANI variable, for AR9003 and later chips; * The AR9003 and later series chips support two RX queues now, so start down the road of supporting that; * Add some new TX queue types - uAPSD is possible on earlier chips, but PAPRD is relevant to AR9003 and later.
Obtained from: Qualcomm Atheros, Linux ath9k
|
#
237622 |
|
27-Jun-2012 |
adrian |
Bring over some new typedefs as part of the AR9300 HAL import.
|
#
237611 |
|
26-Jun-2012 |
adrian |
Bring over the initial 802.11n bluetooth coexistence support code.
The Linux ath9k btcoex code is based off of this code.
Note this doesn't actually implement functional btcoex; there's some driver glue and a whole lot of verification that is required.
On the other hand, I do have the AR9285+BT and AR9287+BT NICs which this code supports..
Obtained from: Qualcomm Atheros, Linux ath9k
|
#
235972 |
|
25-May-2012 |
adrian |
oops - ath_hal_disablepcie is actually destined for another purpose, not to disable the PCIe PHY in prepration for reset.
Extend the enablepci method to have a "poweroff" flag, which if equal to true means the hardware is about to go to sleep.
|
#
234873 |
|
01-May-2012 |
adrian |
Change the MIB cycle count API to return HAL_BOOL, rather than uint32_t, to return whether it was successful.
Add placeholder (blank) methods for previous chips, for both it and the 11n extension channel busy call.
|
#
234749 |
|
28-Apr-2012 |
adrian |
Extend the HAL channel survey statistics:
* include ext_chan_busy; * include ofdm/cck phy error counts, which aren't yet implemented.
|
#
234088 |
|
10-Apr-2012 |
adrian |
Squirrel away the SYNC interrupt in case we're doing interrupt debugging.
|
#
233895 |
|
04-Apr-2012 |
adrian |
Correctly handle AR_MoreAggr when assembling multi-descriptor final frames.
Linux ath9k doesn't have this issue as it doesn't try queuing multi- descriptor frames to the hardware.
Before, I was only setting the first and last descriptor in the final frame correctly - and that was done by accident. The first descriptor in the last sub-frame was being correctly updated by ath_tx_setds_11n(); the last descriptor in the last sub-frame was being correctly updated by ath_buf_set_rate(). But both of those are "incorrect".
The correct behaviour is:
* AR_IsAggr is set for all descriptors for all subframes in an aggregate. * AR_MoreAggr is set for all descriptors for all non-final sub-frames in an aggregate.
Ie, all descriptors in the last sub-frame of an aggregate must have this field set to 0.
I still need to do a couple of extra passes to ensure the pad delimiter field is being correctly handled in all descriptors in the last sub-frame.
|
#
231708 |
|
14-Feb-2012 |
adrian |
Improve the radar register config API.
* Fix the "enabled" flag to actually reflect whether radar detection is enabled or not. * Add flags for the relstep/relpwr checks.
|
#
230147 |
|
15-Jan-2012 |
adrian |
Break out the "memory" EEPROM data read method from being AR9130 specific to being more generic.
Other embedded SoCs also throw the configuration/PCI register info into flash.
For now I'm just hard-coding the AR9280 option (for on-board AR9220's on AP94 and commercial designs (eg D-Link DIR-825.))
TODO:
* Figure out how to support it for all 11n SoC NICs by doing it in ar5416InitState(); * Don't hard-code the EEPROM size - add another field which is set by the relevant chip initialisation code. * 'owl_eep_start_loc' may need to be overridden in some cases to 0x0. I need to do some further digging.
|
#
227410 |
|
09-Nov-2011 |
adrian |
Introduce a work-around for issues with the AR5416 based MAC on SMP devices.
The AR5416 MAC (which shows up in the AR5008, AR9001, AR9002 devices) has issues with PCI transactions on SMP machines. This work-around enforces that register access is serialised through a (global for now) spinlock.
This should stop the hangs people have seen with the AR5416 PCI devices on SMP hosts.
Obtained by: Linux, Atheros
|
#
227375 |
|
09-Nov-2011 |
adrian |
Add a new HAL parameter which forces a full reset rather than warm reset. This forces a full reset of the baseband/radio and seems needed to clear some issues (with Merlin at least) when the baseband gets confused in a very noisy environment.
Sponsored by: Hobnob, Inc.
|
#
227374 |
|
09-Nov-2011 |
adrian |
Port over a new routine which grabs the percentage of time spent in TX frame, RX frame, RX clear, RX extension clear.
This is useful for estimating channel business.
The same routines should be written for AR5210->AR5212 where appopriate.
Obtained from: Atheros
|
#
227365 |
|
08-Nov-2011 |
adrian |
Fix the KTR option to compile by default - it was referencing some unmerged interrupt status debugging code from my branch.
* Add ah_intrstate[8] which will have the record of the last call to ath_hal_getintr(). * Wrap the KTR code behind ATH_KTR_INTR_DEBUG. * Add the HAL interrupt debugging behind AH_INTERRUPT_DEBUGGING.
This is only done for the AR5416 and later NICs but it will be trivial to add to the earlier NICs if required.
Neither are enabled by default, although to minimise HAL binary API differences, the ah_intrstate[] array is always compiled into the ath_hal struct.
|
#
226767 |
|
25-Oct-2011 |
adrian |
Add in some more 11n related HAL methods.
|
#
226488 |
|
18-Oct-2011 |
adrian |
Implement the first part of the BB read workaround.
The AR5008/AR9001 series NICs have a bug where BB register reads will occasionally be corrupted. This could cause issues with things such as ANI, which adjust operational parameters based on the BB radio register reads. This was introduced in the AR5008 chip and fixed with the first released AR9002 series NIC (AR9280v2.)
A followup commit will implement the acutal WAR when reading BB registers. I'm still not sure how I'll implement it - whether it should be done in the osdep layer, or whether it should just live in the AR5416 HAL. Either way, they can use this capability bit to determine whether to implement the WAR or not.
Thankyou to various sources inside Atheros who have helped me track down what this particular issue is.
Obtained from: Atheros
|
#
225444 |
|
08-Sep-2011 |
adrian |
Update the TSF and next-TBTT methods to work for the AR5416 and later NICs. This is another commit in a series of TDMA support fixes for the 11n NICs.
* Move ath_hal_getnexttbtt() into the HAL; write methods for it. This returns a timer value in TSF, rather than TU.
* Move ath_hal_getcca() and ath_hal_setcca() into the HAL too, where they likely now belong.
* Create a new HAL capability: HAL_CAP_LONG_RXDESC_TSF. The pre-11n NICs write 15 bit TSF snapshots into the RX descriptor; the AR5416 and later write 32 bit TSF snapshots into the RX descriptor. * Use the new capability to choose between 15 and 31 bit TSF adjustment functions in ath_extend_tsf().
* Write ar5416GetTsf64() and ar5416SetTsf64() methods. ar5416GetTsf64() tries to compensate for TSF changes at the 32 bit boundary.
According to yin, this fixes the TDMA beaconing on 11n chipsets and TDMA stations can now associate/talk, but there are still issues with traffic stability which need to be investigated.
The ath_hal_extendtsf() function is also used in RX packet timestamping; this may improve adhoc mode on the 11n chipsets. It also will affect the timestamps seen in radiotap frames.
Submitted by: Kang Yin Su <cantona@cantona.net> Approved by: re (kib)
|
#
224716 |
|
08-Aug-2011 |
adrian |
Introduce some more DFS related hooks, inspired both by local work and the Atheros reference code.
The radar detection code needs to know what the current DFS domain is. Since net80211 doesn't currently know this information, it's extracted from the HAL regulatory domain information.
The specifics:
* add a new ath_dfs API hook, ath_dfs_init_radar_filters(), which updates the radar filters whenever the regulatory domain changes. * add HAL_DFS_DOMAIN which describes the currently configured DFS domain . * add a new HAL internal variable which tracks the currently configured HAL DFS domain. * add a new HAL capability, HAL_CAP_DFS_DMN, which returns the currently configured HAL DFS domain setting. * update the HAL DFS domain setting whenever the channel setting is updated.
Since this isn't currently used by any radar code, these should all be no-ops for existing users.
Obtained from: Atheros Submitted by: KBC Networks, sibridge Approved by: re (kib, blanket)
|
#
224709 |
|
08-Aug-2011 |
adrian |
Add another HAL method - ah_isFastClockEnabled - which returns AH_TRUE if 5ghz fast clock is enabled in the current operating mode.
It's slightly dirty, but it's part of the reference HAL and used by the (currently closed-source) radar event code to map radar pulses back to microsecond durations.
Obtained from: Atheros Approved by: re (kib, blanket)
|
#
224633 |
|
03-Aug-2011 |
adrian |
* Fix a clash in structure naming which occurs with (closed source) radar detection code. This is just to make porting the atheros radar code easier.
* add a missing space.
Approved by: re (kib, blanket)
|
#
224539 |
|
31-Jul-2011 |
adrian |
Add extra flags for the radar event API. (They're not used by any public code at the current time.)
Approved by: re (kib)
|
#
224244 |
|
21-Jul-2011 |
adrian |
Modify the radar API a little to be easier to "change" via run-time tools.
* introduce pe_enabled, which (will) indicate whether the radar detection stuff is enabled or not. Right now it's incorrectly set, based on something previously written. I'll sort it out later.
* Don't set HAL_PHYERR_PARAM_ENABLE in pe_relstep to say whether radar detection is on.
* Return whether blockradar, fir128 and enmaxrssi is enabled.
* Change some of the phyerr params to be integers rather than HAL_BOOL so they can be set to the NOPARAM value when the setup function is called. This is in line with other radar parameters.
* Add new configuration parameters for fir128, blockradar and enmaxrssi, rather than defaulting to off, on and on respectively.
Approved by: re (kib)
|
#
223459 |
|
23-Jun-2011 |
adrian |
Break out most of the HAL related tweaks into a per-HAL instance, rather than global variables.
This specifically allows for debugging to be enabled per-NIC, rather than globally.
Since the ath driver doesn't know about AH_DEBUG, and to keep the ABI consistent regardless of whether AH_DEBUG is enabled or not, enable the debug parameter always but only conditionally compile in the debug methods if needed.
The ALQ support is currently still global pending some brainstorming.
Submitted by: ssgriffonuser@gmail.com Reviewed by: adrian, bschmidt
|
#
222815 |
|
07-Jun-2011 |
adrian |
Flesh out a new HAL method to fetch the radar PHY error frame information.
For the AR5211/AR5212, this is apparently a one byte pulse duration counter value. It is only coded up here for the AR5212 as I don't have any AR5211-series hardware to test it on.
This information was extracted from the Madwifi DFS branch along with some local additions.
Please note - all this does is extract out the radar event duration, it in no way reflects the presence of a radar. Further code is needed to take a set of radar events and filter them to extract out correct radar pulse trains (and ignore other events.)
For further information, please see:
http://wiki.freebsd.org/dev/ath_hal%284%29/RadarDetection
This includes references to the relevant patents which describe what is going on.
Obtained from: Madwifi
|
#
222644 |
|
03-Jun-2011 |
adrian |
Bring over the relevant registers to use when implementing the quiet time portion of 802.11h.
The AR5212 code has been brought over as a reference, it's currently untested.
Obtained from: Atheros
|
#
222584 |
|
01-Jun-2011 |
adrian |
Add some missing DFS chipset functionality to the FreeBSD HAL.
Please note - this doesn't in any way constitute a full DFS implementation, it merely adds the relevant capability bits and radar detection threshold register access.
The particulars:
* Add new capability bits outlining what the DFS capabilities are of the various chipsets. * Add HAL methods to set and get the radar related register values. * Add AR5212 and AR5416+ DFS radar related register value routines. * Add a missing HAL phy error code that's related to radar event processing. * Add HAL_PHYERR_PARAM, a data type that encapsulates the radar register values.
The AR5212 routines are just for completeness. The AR5416 routines are a super-set of those; I may later on do a drive-by pass to tidy up duplicate code.
Obtained from: Linux, Atheros
|
#
222277 |
|
25-May-2011 |
adrian |
The current ANI capability information uses a different set of values for the commands, compared to the internal command values (HAL_ANI_CMD.)
My eventual aim is to make the HAL_ANI_CMD internal enum match the public API and then remove all this messiness.
This now allows HAL_CAP_INTMIT users to use a public HAL_CAP_INTMIT_ enum rather than magic constants.
The only magic constants currently used by if_ath are "enable" and "present". Some local tools of mine allow for direct, manual fiddling of the ANI variables and I'll convert these to use the public enum API before I commit them.
|
#
221603 |
|
07-May-2011 |
adrian |
Do a HAL capabilities sync pass based on the Atheros HAL.
* Shuffle some of the capability numbers around to match the Atheros HAL capability IDs, just for consistency.
* Add some new capabilities to FreeBSD from the Atheros HAL which will be be shortly used when new chipsets are added (HAL SGI-20 support is for Kiwi/AR9287 support); for TX aggregation (MBSSID aggregate support, WDS aggregation support); CST/GTT support for carrier sense/TX timeout.
|
#
221581 |
|
07-May-2011 |
adrian |
Add some comments about which HAL capabilities are currently FreeBSD specific.
The Atheros HAL and FreeBSD HAL share the same capabilities up until HAL_CAP_11D, where things begin to diverge.
I'll look at tidying these up soon.
Obtained from: Atheros
|
#
220772 |
|
18-Apr-2011 |
adrian |
Add global TX timeout handling.
The global TX timeout counter increments whenever a frame is ready to be transmitted and the medium is busy.
|
#
220600 |
|
13-Apr-2011 |
adrian |
Add in the last bit of the HAL support for Kite diversity.
* add a new method, specifically for doing per-RX packet antenna diversity * set that HAL method only if it's Kite and a Kite chip that does diversity.
|
#
220444 |
|
08-Apr-2011 |
adrian |
Fix the completely wrong types I used in the previous commit.
|
#
220443 |
|
08-Apr-2011 |
adrian |
Begin fleshing out a public HAL routine to export the per-chain ctl/ext noise floor values.
This routine doesn't check to see whether the radio is MIMO capable - instead, it simply returns either the raw values, the "nominal" values if the raw values aren't yet available or are invalid, or '0' values if there's no valid channel/ no valid MIMO values.
Callers are expected to verify the radio is a MIMO radio (which for now means it's an 11n chipset, there are non-11n MIMO chipsets out there but I don't think we support them, at least in MIMO mode) before exporting the MIMO values.
|
#
220442 |
|
08-Apr-2011 |
adrian |
Export the per-chain ctl/ext noise floor values, raw and uncut, to the upper-level HAL.
Right now the per-chain noise floor values aren't used anywhere in the upper-level HAL, so the driver currently has no real reference to compare the per-chain RSSI values to.
This is needed before per-chain RSSI values (for ctl and ext radios) are can be thrown upstairs to the net80211 code.
|
#
220324 |
|
04-Apr-2011 |
adrian |
Add a HAL capability bit for supporting self-linked RX descriptors and disable it for the 11n chipsets.
From the ath9k source:
==
11N: we can no longer afford to self link the last descriptor. MAC acknowledges BA status as long as it copies frames to host buffer (or rx fifo). This can incorrectly acknowledge packets to a sender if last desc is self-linked.
==
Since this is useful for pre-AR5416 chips that communicate PHY errors via error frames rather than by on-chip counters, leave the support in there, but disable it for AR5416 and later.
|
#
220035 |
|
26-Mar-2011 |
adrian |
.. And another missed commit - add the PSPOLL capability.
|
#
220025 |
|
26-Mar-2011 |
adrian |
Put these two back to mirror what ath9k does.
Even though they map to setting the error filter register, ath9k also writes them untouched to AR_RX_FILTER.
The Force-BSSID match bit can stay high, as it maps to a misc mode register setting rather than an RX filter bit.
|
#
220022 |
|
26-Mar-2011 |
adrian |
Shuffle around the HAL_RX_FILTER bits to be slightly more sensible.
The phyerr, radar and bssid-match bits aren't real bits, they map to enabling bits in other registers. Move those out of the way of valid RX filter bits.
Add a few new fields from ath9k - compba, ps-poll, mcast-bcast-all.
|
#
219790 |
|
20-Mar-2011 |
adrian |
Add a PSPOLL queue type, in preparation for (eventually) porting over the TX queue setup code from ath9k for the AR5416 and later chips.
|
#
219773 |
|
19-Mar-2011 |
adrian |
Add in the channel survey data structures. These will be filled out by the HAL at some point in the future.
|
#
218490 |
|
09-Feb-2011 |
adrian |
Expose the 4k transaction workaround hooks to the driver, but don't (yet) fix the descriptor allocation.
|
#
218150 |
|
01-Feb-2011 |
adrian |
Add a new capability which reports the number of spatial streams a device supports.
The higher levels (net80211, if_ath, ath_rate) need this to make correct choices about what MCS capabilities to advertise and what MCS rates are able to be TXed.
In summary:
* AR5416 - 2/3 antennas, 2x2 streams * AR9160 - 2/3 antennas, 2x2 streams * AR9220 - 2 antennas, 2x2 sstraems * AR9280 - 2 antennas, 2x2 streams * AR9285 - 2 antennas but with antenna diversity, 1x1 stream
|
#
218066 |
|
29-Jan-2011 |
adrian |
Link in the 11n specific TX methods into the HAL.
|
#
218011 |
|
28-Jan-2011 |
adrian |
Bring in some 802.11n packet duration calculation functions from a mix of Sam/Rui and linux ath9k .
This will eventually be used by rate control modules and by the TX code for calculating packet duration when handling rts/cts protection.
Obtained from: sam@, rpaulo@, linux ath9k
|
#
217684 |
|
21-Jan-2011 |
adrian |
ANI changes #1 - split out the ANI polling from the RxMonitor hook.
The rxmonitor hook is called on each received packet. This can get very, very busy as the tx/rx/chanbusy registers are thus read each time a packet is received.
Instead, shuffle out the true per-packet processing which is needed and move the rest of the ANI processing into a periodic event which runs every 100ms by default.
|
#
217624 |
|
20-Jan-2011 |
adrian |
Include the initial support for external EEPROMs.
The AR9100 at least doesn't have an external serial EEPROM attached to the MAC; it instead stores the calibration data in the normal system flash.
I believe earlier parts can do something similar but I haven't experienced it first-hand.
This commit introduces an eepromdata pointer into the API but doesn't at all commit to using it. A future commit will include the glue needed to allow the AR9100 support code to use this data pointer as the EEPROM.
|
#
217621 |
|
20-Jan-2011 |
adrian |
Add a new HAL method to retrieve the completion schedule. It sets the completion schedule from the hardware and returns AH_TRUE if the hardware supports multi-rate retries (AR5212 and above); and returns AH_FALSE if the hardware doesn't support multi-rate retries.
The sample rate module directly reads the TX completion descriptor and extracts the TX schedule information from that. It will be updated in a future commit to instead use this method to determine the completion schedule.
|
#
208711 |
|
01-Jun-2010 |
rpaulo |
Bring in a couple of fixes from the Linux ath9k related to chip hangs. While there, try to make the register write pattern look like what's done by ath9k.
MFC after: 3 days
|
#
203930 |
|
15-Feb-2010 |
rpaulo |
Bring back AR9285 support. This fixes most of the issues and should be pretty usable.
MFC after: 1 month
|
#
195114 |
|
27-Jun-2009 |
sam |
Add HAL_RX_FILTER_BSSID support (to disable bssid match): o add HAL_CAP_BSSIDMATCH to identify parts that have the support for disabling bssid match o honor capability for set/get rx filter o use HAL_CAP_BSSIDMATCH in driver to decide whether to use the bssid match disable or fall back to promisc mode
Reviewed by: rpaulo Approved by: re (rwatson)
|
#
192401 |
|
19-May-2009 |
sam |
correct HAL_INT_BNR comment, this bit is mapped directly the h/w now
|
#
192400 |
|
19-May-2009 |
sam |
add TBTT interrupt support; this was added in Griffin so consumers should check HAL_CAP_INTRMASK before using it
NB: didn't test 11n parts yet so supported only for 5212-class parts
|
#
192397 |
|
19-May-2009 |
sam |
remove special handling for BNR; it is direct mapped to the harwdare so can be added to HAL_INT_COMMON except on the 5210 where it doesn't exist
|
#
192396 |
|
19-May-2009 |
sam |
add HAL_CAP_INTRMASK to return the set of interrupts supported by the device
|
#
190096 |
|
19-Mar-2009 |
sam |
purge hal abi support; now that the hal is merged w/ the driver we cannot be out of sync
MFC after: 1 week
|
#
188979 |
|
24-Feb-2009 |
sam |
Add PCIE power control api: o add ah_configPCIE and ah_disablePCIE for drivers to configure PCIE power save operation (modeled after ath9k, may need changes) o add private state flag to indicate if device is PCIE (replaces private hack in 5212 code) o add serdes programming ini bits for 5416 and later parts and setup for each part (5416 and 9160 logic hand-crafted from existing routines); 5212 remains open-coded but is now hooked in via ah_configPCIE o add PCIE workaround gunk o add ar5416AttachPCIE for iodomatic code used by 5416 and later parts
|
#
188974 |
|
24-Feb-2009 |
sam |
5416 and later parts mux the gpio outputs; extend the api to include a signal type that's used to select the appropriate mux
|
#
188968 |
|
23-Feb-2009 |
sam |
print mac+rf part names; drop the printing 2ghz rf stuff (might come back)
|
#
188770 |
|
19-Feb-2009 |
sam |
whitespace
|
#
187831 |
|
28-Jan-2009 |
sam |
Overhaul regulatory support: o remove HAL_CHANNEL; convert the hal to use net80211 channels; this mostly involves mechanical changes to variable names and channel attribute macros o gut HAL_CHANNEL_PRIVATE as most of the contents are now redundant with the net80211 channel available o change api for ath_hal_init_channels: no more reglass id's, no more outdoor indication (was a noop), anM contents o add ath_hal_getchannels to have the hal construct a channel list without altering runtime state; this is used to retrieve the calibration list for the device in ath_getradiocaps o add ath_hal_set_channels to take a channel list and regulatory data from above and construct internal state to match (maps frequencies for 900MHz cards, setup for CTL lookups, etc) o compact the private channel table: we keep one private channel per frequency instead of one per HAL_CHANNEL; this gives a big space savings and potentially improves ani and calibration by sharing state (to be seen; didn't see anything in testing); a new config option AH_MAXCHAN controls the table size (default to 96 which was chosen to be ~3x the largest expected size) o shrink ani state and change to mirror private channel table (one entry per frequency indexed by ic_devdata) o move ani state flags to private channel state o remove country codes; use net80211 definitions instead o remove GSM regulatory support; it's no longer needed now that we pass in channel lists from above o consolidate ADHOC_NO_11A attribute with DISALLOW_ADHOC_11A o simplify initial channel list construction based on the EEPROM contents; we preserve country code support for now but may want to just fallback to a WWR sku and dispatch the discovered country code up to user space so the channel list can be constructed using the master regdomain tables o defer to net80211 for max antenna gain o eliminate sorting of internal channel table; now that we use ic_devdata as an index, table lookups are O(1) o remove internal copy of the country code; the public one is sufficient o remove AH_SUPPORT_11D conditional compilation; we always support 11d o remove ath_hal_ispublicsafetysku; not needed any more o remove ath_hal_isgsmsku; no more GSM stuff o move Conformance Test Limit (CTL) state from private channel to a lookup using per-band pointers cached in the private state block o remove regulatory class id support; was unused and belongs in net80211 o fix channel list construction to set IEEE80211_CHAN_NOADHOC, IEEE80211_CHAN_NOHOSTAP, and IEEE80211_CHAN_4MSXMIT o remove private channel flags CHANNEL_DFS and CHANNEL_4MS_LIMIT; these are now set in the constructed net80211 channel o store CHANNEL_NFCREQUIRED (Noise Floor Required) channel attribute in one of the driver-private flag bits of the net80211 channel o move 900MHz frequency mapping into the hal; the mapped frequency is stored in the private channel and used throughout the hal (no more mapping in the driver and/or net80211) o remove ath_hal_mhz2ieee; it's no longer needed as net80211 does the calculation and available in the net80211 channel o change noise floor calibration logic to work with compacted private channel table setup; this may require revisiting as we no longer can distinguish channel attributes (e.g. 11b vs 11g vs turbo) but since the data is used only to calculate status data we can live with it for now o change ah_getChipPowerLimits internal method to operate on a single channel instead of all channels in the private channel table o add ath_hal_gethwchannel to map a net80211 channel to a h/w frequency (always the same except for 900MHz channels) o add HAL_EEBADREG and HAL_EEBADCC status codes to better identify regulatory problems o remove CTRY_DEBUG and CTRY_DEFAULT enum's; these come from net80211 now o change ath_hal_getwirelessmodes to really return wireless modes supported by the hardware (was previously applying regulatory constraints) o return channel interference status with IEEE80211_CHANSTATE_CWINT (should change to a callback so hal api's can take const pointers) o remove some #define's no longer needed with the inclusion of <net80211/_ieee80211.h>
Sponsored by: Carlson Wireless
|
#
186333 |
|
19-Dec-2008 |
sam |
add FreeBSD property
|
#
185521 |
|
01-Dec-2008 |
sam |
import ath hal
|
#
185466 |
|
30-Nov-2008 |
sam |
move bus+softc typedefs to ah_osdep.h so we can eliminate the opaque write-around; it doesn't work for some platforms (e.g. ia64) and is now pointless
|
#
185416 |
|
28-Nov-2008 |
sam |
remove ath_hal_buildopts and ath_hal_version; they are not needed any more
|
#
185380 |
|
28-Nov-2008 |
sam |
Update to later code from my repository: o many bug fixes o add new periodic calibration api o break up 5416 periodic calibration code in preparation for 928x o move get noise floor to rf backends o 5416-specific ani (still disabled) o modularize 5210 eeprom format a la other eeprom formats o start cleaning up regdomain code o prepare for proper 1/2 and 1/4 width channel support o bring back 900MHz card support o clean up 5212 rf version handling o add 1/2 and 1/4 width channel support for 5212 parts o split 5212 rfgain handling out o improve ani debugging o add AH_USE_INIPDGAIN compile option o purge a bunch of dead 5212 state o add 1/2 and 1/4 rate modes o remove HAL_CAP_CHAN_HALFRATE and HAL_CAP_CHAN_QUARTERRATE; the same info can now be deduced from the set of supported modes
|
#
185377 |
|
28-Nov-2008 |
sam |
virgin import of ath hal
|