summaryrefslogtreecommitdiffstats
path: root/sys/dev/ic/ar5xxx.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Fix 11g ifmedia modes in ath(4) (shown by 'ifconfig ath0 media').stsp2018-01-311-6/+6
| | | | | | | | | | | | There was code which set them up but didn't include 11b channels which are part of 11g. And there was a hack which effectively stripped important flag bits away and wouldn't work for modes with overlapping channels (b/g). As a result, some flags were missing from 11g channels the driver reported to net80211, which skipped over those channels when building the media list. This gets us one step closer to supporting the AR5424. ok mpi@
* Add comments explaining why the out-of-bounds access in CID 1453077 can'ttb2017-08-251-1/+5
| | | | | | happen. ok mestre, stsp
* Fix off by one overwrite. Covery CID 1452938.mestre2017-08-221-2/+2
| | | | | | | | ee->ee_ctls evaluates to either 16 or 32 depending on the card's EEPROM version and with the current loop condition it will write out of bounds in the second ee->ee_ctls assignment once the condition is either i < 16 or i < 32. OK stsp@ and tb@
* Fix copy pasto (Coverity CID 1452996), with this it matches the code in FreeBSDmestre2017-08-111-2/+2
| | | | OK phessler@ and stsp@
* Remove wireless turbo mode support. It is a non-standard extensionstsp2016-01-121-35/+9
| | | | | | which only worked with ath(4) devices from a decade ago. Diff tested on ath(4) hardware by me to verify that 11a/b modes still work. ok reyk deraadt chris sthen kettenis
* Some reallocarray() use; review Jean-Philippe Ouellet, patrick keshishianderaadt2014-07-131-2/+2
| | | | ok tedu
* add a size argument to free. will be used soon, but for now default to 0.tedu2014-07-121-3/+3
| | | | after discussions with beck deraadt kettenis.
* Fix ar5k_rt_copy() to copy all fields of the HAL_RATE_TABLE struct.stsp2012-01-281-1/+3
| | | | ok mikeb deraadt
* do not attach the AR5416 and AR5418 (AR5416 PCIe) to the ath(4)damien2009-09-231-5/+1
| | | | | | | | driver as these chipsets are not currently supported. noticed by ian@ "makes sense" millert@ ok jsg@
* replace custom macro AR5K_ELEMENTS() with nitems()reyk2009-06-021-17/+17
|
* If a bogus channel is encountered, return an error instead of tryingguenther2009-06-021-1/+5
| | | | | | | to use the -1 flag value as an array index. Found by Parfait. ok reyk@ oga@
* spacingreyk2008-07-301-3/+3
|
* Update the RF, RFGAIN, MODE, INI, and BBGAIN initialization tablesreyk2008-07-301-35/+148
| | | | | | | | | | with different versions for various ar5212 variants and add an extra table for PCI-E devices. This fixes support for various newer devices (like the 1st generation MacBook, T61 variants) but it still does not work on a number of other devices. Tested by many ok deraadt@
* - fix FIFO overruns on PCI-E chipsets by setting the DMA sizereyk2008-07-291-20/+5
| | | | | | | | RX/TX configuration registers to 128 instead of 512 bytes. - add a few more MAC/RF id strings for the dmesg. - check for PCI-E instead of single chip variants in a few places. ok deraadt@
* syncreyk2008-07-281-2/+2
|
* syncreyk2008-07-281-2/+2
|
* Check for G channels before B when setting the (eeprom) mode.fgsch2007-12-031-7/+9
| | | | based on a change from Luis R. Rodriguez <mcgrof at gmail dot com>. reyk@ ok
* add the AR5416 and AR5418 device IDs (needs some more testing)reyk2007-10-131-1/+5
|
* The newer single chip Atheros wireless chipsets like the AR5424,reyk2007-10-121-4/+25
| | | | | | | | | | | | | | | | | | | AR2423 etc. are mostly compatible to the AR5212 but use a different algorithm to set the 2GHz RF channel, that's why they didn't work in OpenBSD. I figured out that the channels were set with an offset, setting channel 11 in the driver caused the hardware to set channel 5 etc. Because I didn't figure out the pattern to fix the algoritm yet, I fixed it in a workaroundish way by defining a small "table" with offsets for the 11b channels to get the right results. For example, if we want to set channel 11 (2462MHz), we add an offset of -30MHz, and feed the result (2432MHz ^= channel 5) into the unmodified AR5212/AR5112 RF setup function. Long description for a commit message, but it needed some time to figure it out. It is still not perfect, needs some more work, and it doesn't work in all cases; but it allows to use newer chipsets in 11b mode restricted to 1 or to 2Mbit/s. 11a mode seems to work without problems so far.
* KNFgilles2007-09-111-4/+4
| | | | prompted and "much better" by marco@, ok pyr@
* use M_ZEROreyk2007-09-071-6/+4
|
* Implement bit swap for a byte in O(log(N)) rather than O(N), promptedtom2007-06-261-7/+15
| | | | | | by an interview question I was asked. ok reyk@
* remove the internal wrapper functions for ieee80211_mhz2ieee andreyk2007-05-091-14/+2
| | | | | | ieee80211_ieee2mhz which also removes some dead code. figured out by deraadt@
* The integrated Atheros NICs found in IBM/Lenovo ThinkPads use the samereyk2007-04-131-4/+20
| | | | | | | | | | | | | | device ID for old AR5212-based 32bit and new AR5424-based 64bit (PCI Express Mini Card) interfaces. Use an extra check to look if the card is 64bit and attach it as a single chip device. This prevents a panic when attaching the device on some laptops like the T60. Tested on a T42 (old AR5212 Mini PCI interface), Tested on a T60 (new AR5424 Mini Card interface) Nevertheless, the AR5424 does not work yet. Thanks to Stefan Konrath
* add some HAL functions (again) inspired by the changes from thereyk2007-03-121-2/+2
| | | | | madwifi-old-openhal project. this was backed out the last time because it was too close to the release and i didn't respect the ABI/API lock.
* back out, reyk is not paying attentionderaadt2007-03-051-2/+2
|
* Add some HAL functions.reyk2007-03-051-2/+2
| | | | | | From madwifi-old-openhal via Nick Kossifidis (mickflemm at gmail dot com) Bump copyright while I'm here.
* figured out by tdeval@:reyk2006-11-061-1/+18
| | | | | >During factorization in 1.57, the switch block was moved too early. >Hence it's updating an uninitialized ah structure.
* detect the newer single chip generations AR2413, AR5413 and AR5224 butreyk2006-09-191-1/+15
| | | | don't attach them, yet.
* disable 11g mode for nowreyk2006-09-191-3/+5
|
* start to sync some changes and fixes from various "openhal" ports ofreyk2006-06-051-10/+47
| | | | | | | this driver. thanks for contribution (even if i didn't get much feedback from these projects...). tested by many during c2k6, like aanriot@ and ian@
* Update my e-mail address in the copyright statement, no binary changes.reyk2005-12-181-2/+2
|
* cleanup and simplify the regulation domain handling. some devices arereyk2005-09-231-48/+33
| | | | | | | | | known to have a broken/unsupported regulation domain stored in their EEPROM, we use the default instead (Canada). there's no need to manually define COUNTRYCODE in ar5xxx.c anymore for invalid EEPROMs but it's still possible to force a specific country - your choice. ok aanriot@
* don't attach unsupported radio chipsetsreyk2005-09-191-2/+2
| | | | based on a diff by jsg@
* ansi, no binary change.jsg2005-09-101-132/+46
| | | | ok reyk@
* fix compiling with AR5K_DEBUG. thanks to Bernd Ahlers.reyk2005-08-171-2/+2
|
* reduce stack usagereyk2005-08-021-12/+13
| | | | spotted out by jsg@
* remove non-constant array initializers which is a GNU extension.reyk2005-06-171-4/+8
| | | | suggested by anil some time ago.
* fix hostap modereyk2005-05-281-2/+2
|
* - disable the gpio user interface for now, it's just an unimportantreyk2005-05-271-9/+2
| | | | | | | button which is not yet available on non-i386 platforms - fix endianess and attachement on big endian platforms (tested on macppc - ath attaches correctly, receives frames but assoc still fails)
* remove an extra delay in rf register initreyk2005-05-161-4/+2
|
* change the dmesg output: print known chipset names, don't print thereyk2005-05-081-1/+23
| | | | | | supported 802.11a/b/g modes (this could be discovered with ifconfig -m athX). inspired by Johan M:son Lindman and others asking about the several different ARxxxx chipset combos.
* beautify the code by renaming HAL functions with capitalized words (ireyk2005-04-181-8/+8
| | | | | always wanted to do that). this breaks HAL compatibility but porting should be easy, have a look at athvar.h. no functional changes.
* some fixes for wep and reset.reyk2005-03-201-6/+5
| | | | | | btw.: this is a commit using an ar5212 in 11b mode... ok deraadt@, krw@
* further fixes for ar5212.reyk2005-03-191-16/+83
|
* improve ar5212 init on resetreyk2005-03-181-66/+241
|
* fix beacon handlingreyk2005-03-101-6/+9
|
* improve radiotap support, fix some minor bugs.reyk2005-03-031-2/+3
|
* add support for the atheros ar5211 802.11A/B/g wireless chipset.reyk2005-02-251-5/+34
| | | | ok deraadt@
* add all supported regulation domains. the forced COUNTRYCODE in ar5xxxreyk2005-02-231-32/+90
| | | | | | is now disabled by default to use the value found in EEPROM. ok deraadt@