summaryrefslogtreecommitdiff
path: root/sys/dev/ath/if_ath.c
Commit message (Collapse)AuthorAgeFilesLines
...
* make superg/fast-frames state dynamically-allocated (and indirect offSam Leffler2009-05-021-7/+2
| | | | | | | | the com structure instead of embedded); this reduces the overhead when not configured and reduces visibility of the contents Notes: svn path=/head/; revision=191753
* don't use caddr_t to match ieee80211_dump_pkt type; supplying the correctSam Leffler2009-04-131-7/+8
| | | | | | | one costs nothing Notes: svn path=/head/; revision=191021
* o fix dynamic slave-side tdma slot length updating: we need to re-setup theSam Leffler2009-04-131-1/+2
| | | | | | | | burst length in the tx q's o remove re-config of the beaconq on update; it's not needed Notes: svn path=/head/; revision=191020
* remove reference to sc_tdmabintcnt; it was removed in r190848Sam Leffler2009-04-131-1/+0
| | | | Notes: svn path=/head/; revision=190986
* Hoist 802.11 encapsulation up into net80211:Sam Leffler2009-03-301-381/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | o call ieee80211_encap in ieee80211_start so frames passed down to drivers are already encapsulated o remove ieee80211_encap calls in drivers o fixup wi so it recreates the 802.3 head it requires from the 802.11 header contents o move fast-frame aggregation from ath to net80211 (conditional on IEEE80211_SUPPORT_SUPERG): - aggregation is now done in ieee80211_start; it is enabled when the packets/sec exceeds ieee80211_ffppsmin (net.wlan.ffppsmin) and frames are held on a staging queue according to ieee80211_ffagemax (net.wlan.ffagemax) to wait for a frame to combine with - drivers must call back to age/flush the staging queue (ath does this on tx done, at swba, and on rx according to the state of the tx queues and/or the contents of the staging queue) - remove fast-frame-related data structures from ath - add ieee80211_ff_node_init and ieee80211_ff_node_cleanup to handle per-node fast-frames state (we reuse 11n tx ampdu state) o change ieee80211_encap calling convention to include an explicit vap so frames coming through a WDS vap are recognized w/o setting M_WDS With these changes any device able to tx/rx 3Kbyte+ frames can use fast-frames. Reviewed by: thompsa, rpaulo, avatar, imp, sephe Notes: svn path=/head/; revision=190579
* Remove ATH_SUPPORT_TDMA and use IEEE80211_SUPPORT_TDMA instead. ItSam Leffler2009-03-301-25/+26
| | | | | | | | doesn't make much sense to configure driver support w/o net80211. Note this means ath now depends on opt_wlan.h. Notes: svn path=/head/; revision=190571
* Eliminate ic_myaddr so changing the mac address of a device works correctly:Sam Leffler2009-03-291-13/+5
| | | | | | | | | | | | | | o remove ic_myaddr from ieee80211com o change ieee80211_ifattach to take the mac address of the physical device and use that to setup the lladdr. o replace all references to ic_myaddr in drivers by IF_LLADDR o related cleanups (e.g. kill dead code) PR: kern/133178 Reviewed by: thompsa, rpaulo Notes: svn path=/head/; revision=190526
* purge hal abi support; now that the hal is merged w/ the driverSam Leffler2009-03-191-25/+0
| | | | | | | | | we cannot be out of sync MFC after: 1 week Notes: svn path=/head/; revision=190096
* Minor cleanups of tdma protocol handling:Sam Leffler2009-03-181-3/+3
| | | | | | | | | | | | | | o break out version-related code to simplify rev'ing the protocol o add parameter validation macros so checks that appear multiple places are consistent (and easy to change) o add protocol version check when looking for a scan candidate o improve scan debug output format o rewrite beacon update handling to calculate a bitmask of changed values and pass that down through the driver callback so drivers can optimize work o do slot bounds check before use when parsing received beacons Notes: svn path=/head/; revision=189980
* replace if_watchdog w/ private callout; probably can merge this with theSam Leffler2009-03-091-14/+19
| | | | | | | calibration work sometime in the future Notes: svn path=/head/; revision=189605
* add a sysctl to ena/dis frobbing ccaSam Leffler2009-03-051-1/+21
| | | | Notes: svn path=/head/; revision=189380
* 5416 and later parts mux the gpio outputs; extend the api to includeSam Leffler2009-02-241-4/+8
| | | | | | | a signal type that's used to select the appropriate mux Notes: svn path=/head/; revision=188974
* print mac+rf part names; drop the printing 2ghz rf stuff (might come back)Sam Leffler2009-02-231-26/+3
| | | | Notes: svn path=/head/; revision=188968
* remove private support for IEEE80211_MODE_HALF and IEEE80211_MODE_QUARTERSam Leffler2009-02-191-6/+1
| | | | | | | now that net80211 has them Notes: svn path=/head/; revision=188783
* add SIOCZATHSTATS ioctl to zero driver statisticsSam Leffler2009-02-131-0/+6
| | | | Notes: svn path=/head/; revision=188557
* add driver stat to count tx drops due to insufficient frag buffersSam Leffler2009-02-131-2/+1
| | | | Notes: svn path=/head/; revision=188555
* don't do phantom beacon miss checking for s/w beacon miss handling,Sam Leffler2009-02-101-17/+22
| | | | | | | | this can mistakenly drop events that cause the s/w bmiss timer to never get re-armed Notes: svn path=/head/; revision=188465
* mark the CLR key installed for open auth stations such that it is reclaimedSam Leffler2009-02-101-0/+2
| | | | | | | when net80211 tears down station state; without this we leak keycache slots Notes: svn path=/head/; revision=188447
* add hw.ath.bstuck to control the stuck beacon thresholdSam Leffler2009-02-101-2/+6
| | | | Notes: svn path=/head/; revision=188446
* on resume ah_curchan may be NULL if no channel change has been done;Sam Leffler2009-02-101-1/+3
| | | | | | | | | | workaround this by passing net80211's channel as we know it'll never be null Submitted by: trasz Notes: svn path=/head/; revision=188445
* count stuck beacon eventsSam Leffler2009-02-071-0/+1
| | | | Notes: svn path=/head/; revision=188269
* Minor packet drop improvements:Sam Leffler2009-02-051-3/+8
| | | | | | | | | | | o change tdma packet drop msg when ack required to ATH_DEBUG_TDMA (ATH_DEBUG_XMIT is too noisy) o add a debug msg for raw packet drop due to interface down/invalid o add stats for these two cases o explain how another drop case is handled Notes: svn path=/head/; revision=188195
* Overhaul regulatory support:Sam Leffler2009-01-281-282/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 Notes: svn path=/head/; revision=187831
* change ic_getradiocaps driver callback to include the max # channelsSam Leffler2009-01-271-2/+2
| | | | | | | so callers know the size of the array passed down Notes: svn path=/head/; revision=187800
* don't run the calibration code if scanning, we won't be on the home channelSam Leffler2009-01-231-0/+4
| | | | Notes: svn path=/head/; revision=187608
* TDMA support for long distance point-to-point links using ath devices:Sam Leffler2009-01-081-45/+695
| | | | | | | | | | | | | | | | | | o add net80211 support for a tdma vap that is built on top of the existing adhoc-demo support o add tdma scheduling of frame transmission to the ath driver; it's conceivable other devices might be capable of this too in which case they can make use of the 802.11 protocol additions etc. o add minor bits to user tools that need to know: ifconfig to setup and configure, new statistics in athstats, and new debug mask bits While the architecture can support >2 slots in a TDMA BSS the current design is intended (and tested) for only 2 slots. Sponsored by: Intel Notes: svn path=/head/; revision=186904
* honor IEEE80211_BPF_CRYPTO for raw xmit; fixes shared key auth in sta modeSam Leffler2008-12-071-2/+50
| | | | | | | PR: kern/129022 Notes: svn path=/head/; revision=185745
* New periodic calibration scheme needed for 11n parts that haveSam Leffler2008-12-071-51/+78
| | | | | | | | | | | | | | | | | | multiple algorithms and potentially collect multiple samples. Instead of a single calibration interval we now have short and long intervals; the long interval roughly corresponds to the previous single interval. The short interval is used to speedup collection of samples and happens much quicker. We make calls using the short interval until we're told the calibration work is complete at which point we fallback to the long interval. In addition there is a much longer reset interval used to flush all calibration state and cause everthing to start anew. With these changes you can also disable calibration entirely by setting the long interval to zero. Notes: svn path=/head/; revision=185744
* Switch to ath hal source code. Note this removes the ath_halSam Leffler2008-12-011-2/+1
| | | | | | | | | | | | | | | | | | | | module; the ath module now brings in the hal support. Kernel config files are almost backwards compatible; supplying device ath_hal gives you the same chip support that the binary hal did but you must also include options AH_SUPPORT_AR5416 to enable the extended format descriptors used by 11n parts. It is now possible to control the chip support included in a build by specifying exactly which chips are to be supported in the config file; consult ath_hal(4) for information. Notes: svn path=/head/; revision=185522
* sync w/ p4 branchSam Leffler2008-11-301-1/+2
| | | | Notes: svn path=/head/; revision=185481
* some of the 11n parts can hang under certain conditions withoutSam Leffler2008-11-301-2/+28
| | | | | | | | | | necessary workarounds, add code to detect these hangs and distinguish them from other events; note this code is only invoked for anomalous conditions and (at the moment) is a noop because the hang detection code is in a new hal that's coming shortly Notes: svn path=/head/; revision=185480
* add frequency mapping for the Zcomax GZ-901Sam Leffler2008-11-301-4/+9
| | | | Notes: svn path=/head/; revision=185479
* print the extended tx/rx descriptor for 5416 and later partsSam Leffler2008-11-241-9/+32
| | | | Notes: svn path=/head/; revision=185243
* nuke special handling of RXORN interrupt; the hal marks the FATALSam Leffler2008-11-241-16/+4
| | | | | | | | bit in the interrupt status when RXORN is hit and the chip requires a reset so our special handling was causing useless resets Notes: svn path=/head/; revision=185242
* Fix checks for fast frames negotiation. ni_ath_flags holds theSam Leffler2008-10-301-1/+1
| | | | | | | | | | | | | | | | | capabilities reported by the ap. These need to be cross-checked against the local configuration in the vap. Previously we were only checking the ap capabilities which meant that if an ap reported it was ff-capable but we were not setup to use them we'd try to do ff aggregation and drop the frame. There are a number of problems to be fixed here but applying this fix immediately as the problem causes all traffic to stop (and has not workaround). Reported by: Ashish Shukla Notes: svn path=/head/; revision=184480
* prepare for a new halSam Leffler2008-10-271-9/+13
| | | | Notes: svn path=/head/; revision=184369
* o With the addition of HT rates the set of h/w codes has a much wider rangeSam Leffler2008-10-271-52/+39
| | | | | | | | | | | | | | making the use of sc_hwmap to do direct mapping impractical. Switch to indexing by the rate index instead of the rate code and adjust associated state and logic appropriately. This has several benefits including simplification of the led code. o fix radiotap capture of HT rates o fix conditional compilation of HT radiotap support to be based on the hal having 5416 support; not the ABI version as hal builds may or may not include 5416 support Notes: svn path=/head/; revision=184368
* prefer #define to naked constantSam Leffler2008-10-271-1/+1
| | | | Notes: svn path=/head/; revision=184366
* fix handling of HT rates; these overlap legacy rates and need to beSam Leffler2008-10-271-2/+7
| | | | | | | marked as MCS in the inverse mapping table Notes: svn path=/head/; revision=184365
* add hack to deal with Ubiquiti XR9 cards, they have a different mappingSam Leffler2008-10-271-9/+24
| | | | | | | | between 900MHz and 2.4GHz frequencies than SR9 cards; they are distinguished by different country codes Notes: svn path=/head/; revision=184364
* install bssid for ahdemo mode tooSam Leffler2008-10-271-0/+1
| | | | Notes: svn path=/head/; revision=184361
* fix commentSam Leffler2008-10-271-1/+1
| | | | Notes: svn path=/head/; revision=184360
* correct callback status parameter; only indicate success when an ACK wasSam Leffler2008-10-271-1/+2
| | | | | | | received Notes: svn path=/head/; revision=184359
* Fixup statistics:Sam Leffler2008-10-271-10/+13
| | | | | | | | | | o update tx rssi data only when an ACK was received o return tx rssi from sampled data instead of the last frame o track noise floor o return rx rssi and noise floor (was broken) Notes: svn path=/head/; revision=184358
* update the sta inactivity timer only if we actually received an ACKSam Leffler2008-10-271-1/+2
| | | | Notes: svn path=/head/; revision=184357
* Regdomain fixups:Sam Leffler2008-10-271-18/+55
| | | | | | | | | | | | | | o pass country code, outdoor indication, and ecm mode into the hal when requesting a channel list o add a console msg when regulatory setup fails o add placeholder code to map between Atheros sku's and 802.11 sku's that handles only the debug country code used to unlock the full channel list (to be used only for debugging) o fix multiple instances of mismapping the 802.11 location to the outdoor indication (anywhere may be outdoor also) Notes: svn path=/head/; revision=184356
* add regdomain debug msgsSam Leffler2008-10-271-0/+18
| | | | Notes: svn path=/head/; revision=184355
* add sys.dev.ath.X.intmit knob to enable/disable ANISam Leffler2008-10-271-0/+18
| | | | | | | (the intmit name is historical) Notes: svn path=/head/; revision=184354
* shuffle debug setup to simplify debugging events during attachSam Leffler2008-10-271-5/+8
| | | | Notes: svn path=/head/; revision=184353
* rename bf_flags to bf_txflags in preparation for the addition of flagsSam Leffler2008-10-271-4/+4
| | | | | | | separate from the tx descriptor flags currently recorded Notes: svn path=/head/; revision=184351