aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
Commit message (Collapse)AuthorAge
...
* | | ath5k: Support synth-only channel change for AR2413/AR5413Nick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add synth-only channel change for AR2413/5413. When we call ath5k_reset with a channel ath5k_hw_reset will first try to set channel on PHY while PHY is running instead of doing a normal full reset. To do this phy_init has to change to implement this functionality. * Clean up change_channel flag, what it really did was skip PCU registers when setting initvals. This is done because on reset PCU registers are not affected (except the registers we set in pcu init and -due to hw problems- TSF). Use a new skip_pcu flag that's not misleading instead. In the future we might use that to also skip PCU reset and save us the TSF etc problems (needs testing because standard practice is to reset everything). * Use fast channel change only when setting channel, and set skip_pcu to false only on init. When we reset the card due to DMA or PHY problems skip pcu but never do a fast channel change. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Skip powertable setting when we are on the same channelNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Only set power table if we are changing channel/mode there is no need to recalculate and reset the power table all the time. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Update PLL programming for turbo/half/quarterNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | * Set correct PLL settings for each bwmode Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Update spur mitigation filter for turbo/half/quarterNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | * Add spur mitigation filter support for half/quarter and turbo. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Tweak power detector delays on RF5111/RF5112Nick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Tweak power detector delays on AR5111/AR5112 when using half/quarter modes. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Always set IFS intervals on resetNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Make sure we always set IFS timings even if no coverage class is set. If we don't we'll miss the needed changes for different bwmodes. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Use turbo flag on DCUNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Set AR5K_DCU_GBL_IFS_MISC_TURBO_MODE flag on DCU when operating on 40MHz Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Set all IFS intervals, not just slot timeNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Replace set_slot_time with set_ifs_intervals that also sets the various inter-frame space intervals based on current bwmode. * Clean up AR5210 mess from reset_tx_queue, AR5210 only has one data queue and we set IFS intervals for that queue on set_ifs_intervals so there is nothing left to do for 5210 on reset_tx_queue. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Extend rate_durationNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Extend ieee80211_generic_frame_duration to support the various bwmodes. * Better document what's going on with ack bitrates and update write_rate_duration to support the standard ack bitrates (when we don't set the high bit). * Get rid of set_ack_bitrate_high and introduce a flag on ath5k_hw for this (we only called the function on init anyway so there is no difference). Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Extend get_default_sifs/slot_timeNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Extend get_default_sifs/slot_time to include timings for turbo half and quarter rate modes. * AR5210 code for now uses timings already on core clock units instead of usecs so rename them (we 'll clean it up later). Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Move tx retries setting outside reset_tx_queueNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Move setting of tx retry limits on a separate function (we 'll clean up this AR5210 mess later) Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Increase PHY settling parameters for turo modeNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * On turbo mode increase PHY settling times, note that we only increase switch settling time on AR5212 as indicated by initvals. * A few cleanups: Move frame control settings for AR5210 from reset_tx_queue to tweak_initvals and remove phy_scal settings from tweak_initvals (we tweak them alread on set_sleep_clock). Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Small cleanup on tweak_initvalsNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Now that we properly set rx/tx latencies for AR5311 remove that old buggy part of code left inside ath5k_hw_tweak_initval_settings that was never executed (you can't have an RF5112 radio on a mac older than AR5212). Also use a magic value for 5311 PHY_SCAL value. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Put core clock initialization on a new functionNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Handle all usec parameters in one function. It's much cleaner this way. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Add new field on ath5k_hw to track bandwidth modesNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Prepare for half/quarter/turbo support, introduce a new ah_bwmode parameter and get rid of ah_turbo. Bwmode stands for "bandwidth mode" and can have 4 values, default (20MHz), turbo (40MHz), half rate (10MHz), and quarter rate (5MHz). Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Use new function to stop beacon queueNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Since we only use ath5k_hw_stop_tx_dma to stop the beacon queue, introduce a new function ath5k_hw_stop_beacon_queue so that we can use that instead and have better control. In the future we can add more beacon queue specific stuff there (maybe tweak beacon timers or something), for now just call ath5k_hw_stop_tx_dma. * Also since we don't call ath5k_hw_stop_rx/tx_dma from outside dma.c, make them static. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Check RXE when setting RXDPNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Make sure we are not trying to set RXDP while RX is active, for now ignore the return value. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Use DCU early termination correctlyNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * DCU early termination should be used to quickly flush QCU according to docs so don't enable it for all queues, enable it only when stopping each queue and disable it when we are done. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Debug DMA timeoutsNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Increase timeouts on ath5k_hw_stop_tx_dma and also wait for tx queue to stop before checking for pending frames * Add a new debug level to debug dma start/stop Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Use new dma_stop function on base.cNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Since we stop rx/tx dma and pcu durring reset there is no need to call ath5k_hw_stop_rx/tx_dma before, also there is no need to call them durring stop_locked since we can use ath5k_hw_dma_stop for both. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Stop PCU on resetNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Stop PCU receive logic (DRU) durring reset We need to be sure pcu is not active when trying to stop rx dma right now this is done on ath5k_reset (base.c) but later we are going to clean it up. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Add new function to stop rx/tx DMANick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | * Add a new function to stop rx/tx dma and use in when reset starts Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath5k: Reset cleanup and generic cleanupNick Kossifidis2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * No functional changes * Clean up reset: Introduce init functions for each unit and call them instead of having everything inside ath5k_hw_reset (it's just c/p for now so nothing changes except calling order -I tested it with various cards and it's ok-) * Further cleanups: ofdm_timings belongs to phy.c rate_duration belongs to pcu.c clock functions are general and belong to reset.c (more to follow) * Reorder functions for better organization: We start with helpers and other functions follow in categories, init functions are last Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath9k: Add support for Adaptive Power ManagementMohammed Shafi Shajakhan2010-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This feature is to mitigate the problem of certain 3 stream chips that exceed the PCIe power requirements.An EEPROM flag controls which chips have APM enabled which is basically read from miscellaneous configuration element of the EEPROM header. This workaround will reduce power consumption by using 2 Tx chains for Single and Double stream rates (5 GHz only).All self generated frames (regardless of rate) are sent on 2 chains when this feature is enabled(Chip Limitation). Cc: Paul Shaw <paul.shaw@atheros.com> Signed-off-by: Mohammed Shafi Shajakhan <mshajakhan@atheros.com> Tested-by: Mohammed Shafi Shajakhan <mshajakhan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath9k: fix software retry counter trackingFelix Fietkau2010-11-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The recent tx path cleanups moved the software retry count tracking from the ath_buf to the skb cb, however the actual counter update referred to the wrong location, confusing block-ack window tracking. Fix this by using the retries counter in the struct ath_frame_info. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | Revert "ath9k_htc: Handle monitor mode properly for HTC devices"Rajkumar Manoharan2010-11-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 446fad5a5b6be765c8ec39bfdbbc6c7aa63fbcbb. The change had broken the packet injection on monitoring mode. Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath9k: Remove code which enables btcoex based on subsys idVasanthakumar Thiagarajan2010-11-29
| | | | | | | | | | | | | | | Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath9k: Reintroduce modparam to enable btcoexVasanthakumar Thiagarajan2010-11-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is not ideal to enable btcoex based on subsys id as it is not unique, they are so random. It is also a pain keeping all of them in a table to enable btcoex for a particular hw. Going back to the old idea. Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | iwlagn: minor change in bt coex normal LUTWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | Minor changes in LUT Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: use different kill mask when SCO activeWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | use different kill_ack_mask and kill_cts_mask when detect SCO is active. Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: Offical name for 100/130 deviceWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change to offical name for 100 devices: "Intel(R) Centrino(R) Wireless-N 100" Change to offical name for 130 devices: "Intel(R) Centrino(R) Wireless-N 130" Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: Offical name for 6000g2b deviceWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | Change to offical name for 6000g2b devices: "Intel(R) Centrino(R) Wireless-N 1030" "Intel(R) Centrino(R) Advanced-N 6230" Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: Offical name for 6000g2a deviceWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | Change to offical name for 6000g2a devices: "Intel(R) Centrino(R) Advanced-N 6205" Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: Offical name for 6050g2 deviceWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | Change to offical name for 6050g2 devices: "Intel(R) Centrino(R) Wireless-N 6150" Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlwifi: use mac80211 AC definesJohannes Berg2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of hardcoding the numbers that must match mac80211, use the constants. Not that this means we could change the constants, but at least this way it's clearer. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: advertise reliable TX statusJohannes Berg2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our hardware has reliable TX status, but we're not currently advertising that to mac80211. Since the packet loss monitoring will depend on it, advertise it. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: fix station powersave accounting for aggregationJohannes Berg2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since aggregation queues are station-specific, the device will not reject packets in them but rather will stop the appropriate aggregation queues when a station goes to sleep. I forgot to account for this in the driver, so if a station went to sleep that had aggregation enabled, traffic would stop indefinitely. Fix this by only accounting frames queued on the normal AC queues for associated station. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlagn: remove powersave warningJohannes Berg2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Through races, a packet may be enqueued for transmission to a station while that station is going to sleep, in which case the warning here triggers. Instead of warning, check the condition -- if this packet is not a PS-poll response then we still enqueue it but it will be rejected by the device since the station is marked as asleep. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlwifi: use antenna information in EEPROMWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The valid tx/rx antenna information is part of EEPROM, so use it to configure the device. For few cases, the EEPROM did not reflect the correct antenna, but it is too late to modify the EEPROM, so overwrite with .cfg parameters Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | iwlwifi: remove unused defineWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | was not used, remove it Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
* | | ath9k_hw: remove ath9k_hw_stoppcurecvFelix Fietkau2010-11-24
| | | | | | | | | | | | | | | | | | | | | It is no longer used anywhere Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath9k_htc: Identify devices using driver_infoRajkumar Manoharan2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | Categorize AR7010 & AR9287 devices based on driver_info of usb_device_id, instead of PIDs. This avoids per-device cases and minimize code changes for new device addition. Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath9k_hw: Fix eeprom offset for AR9287 devices (PCI/USB)Rajkumar Manoharan2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | AR9287 devices (PCI/USB) use different eeprom start location to read nvram. New devices might endup with same devid. So use driver_info to set offset, instead of devid. driver_info is valid for HTC devices alone which is filled in usb_device_id. Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath9k_htc: Add driver_info in usb device listRajkumar Manoharan2010-11-24
| | | | | | | | | | | | | | | | | | | | | Added driver_info to identify AR7010, R9287 HTC devices. Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | ath: Add a driver_info bitmask fieldRajkumar Manoharan2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The driver_info stores the device category information which is used to load appropriate device firmware, select firmware offset and eeprom starting location. The driver_info is accessed across ath9k_htc and ath9k_hw. Hence placed under common structure. Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | iwlwifi: advance power management supportWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | For 6000g2b and up, adding advance power management support for better power consumption Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | iwlwifi: power management checking for shadow registerWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | If shadow register is enable, modify the power management command to inform uCode Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | iwlwifi: consider BT for power managementWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | Check the BT PSPoll flag when fill PM command to uCode Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | iwlwifi: add more power management flagsWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | Adding additional power management option available for the device. Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | | iwlagn: name change for BT config flagWey-Yi Guy2010-11-24
| | | | | | | | | | | | | | | | | | | | | | | | Bit 7 of BT config flag is used to enable/disable PSPoll sync. Make the name to match it. Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>