aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k
Commit message (Collapse)AuthorAge
...
| * | ath9k: Remove useless return value checkSujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | ath_init_btcoex_timer() always returns 0, so checking for error conditions is not required. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: add per-vif TX power capability to TX pathLorenzo Bianconi2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to add per-vif TX power capability cap per-packet TX power to vif configured power if the latter is lower than per-rate TX power and mac80211 per-frame power. Use vif TX power if TPC has been disabled for current the interface Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: add per-vif TX power capabilityLorenzo Bianconi2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | Configure the HW with highest TX power among all vif when HW TPC has been enabled in order to add support to per-vif TX power capability. Use lowest configured power among all interfaces when TPC is disabled Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Mute BT properlySujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | Set The BT/WLAN priority weights correctly and make sure that MCI_LNA_TAKE is sent only for cards that share PA/LNA. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Fix GPM initializationSujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | Handle MCI_STATE_INIT_GPM_OFFSET separately and do not overload ar9003_mci_get_next_gpm_offset() with a special case. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Prepare MCI interface correctlySujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | The LNA_TRANS message needs to be sent only for chips which have shared PA/LNA. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Setup MCI statistics properlySujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | Use a subroutine to enable MCI debug statistics if it is present in the global configuration. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Fix MCI TX controlSujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | This patch makes sure that the antenna configuration is used properly when setting AR_MCI_TX_CTRL. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Handle 2-ANT AR9565 in MCI resetSujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | The value programmed in the BTCOEX control register is different for each chip. This patch adds support for 2-ANT, 1-ANT solutions based on AR9565. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Add new MCI configuration parametersSujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | Several new MCI parameters need to be handled for new chips, add them. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Remove useless check in MCI resetSujith Manoharan2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | If we fail to allocate the sched/gpm buffers when initializing MCI, we bail out properly. Checking them in ar9003_mci_reset() is unnecessary, so remove it. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Move MCI registers to reg_mci.hSujith Manoharan2015-03-03
| | | | | | | | | | | | | | | Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k_htc: Add new USB IDLeon Nardella2015-02-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This device is a dongle made by Philips to enhance their TVs with wireless capabilities, but works flawlessly on any upstream kernel, provided that the ath9k_htc module is attached to it. It's correctly recognized by lsusb as "0471:209e Philips (or NXP) PTA01 Wireless Adapter" and the patch has been tested on real hardware. Signed-off-by: Leon Nardella <leon.nardella@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Restart TSF2 timers on wakeupSujith Manoharan2015-02-26
| | | | | | | | | | | | | | | | | | | | | | | | When coming out of WoW sleep, check and restart timers based on TSF2. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Clear additional WoW eventsSujith Manoharan2015-02-26
| | | | | | | | | | | | | | | | | | | | | | | | The events for patterns 8..15 need to be cleared on wakeup. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Handle additional patterns on wakeupSujith Manoharan2015-02-26
| | | | | | | | | | | | | | | | | | | | | | | | Handle the user-configured patterns in the range 8..15 when waking up and update wow_status correctly. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Check MCI PowerSave stateSujith Manoharan2015-02-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The power save state of MCI has to be disabled when enabling WoW sleep, check this properly. ar9003_mci_state() doesn't handle MCI_STATE_GET_WLAN_PS_STATE right now, but this will be done later when proper support for MCI/PS is added. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Add new MCI statesSujith Manoharan2015-02-26
| | | | | | | | | | | | | | | | | | | | | | | | Several new MCI states have to handled, add them to the list. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Set keep awake timerSujith Manoharan2015-02-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When MCI is enabled and WoW sleep is enabled, make sure that the RTC keep awake timer is set with the required value. This is also required when the AR_WA is programmed. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * | ath9k: Fix descriptors for keep-alive frameSujith Manoharan2015-02-26
| |/ | | | | | | | | | | | | | | | | | | Along with AR9462, AR9565 also has an extra field in the TX descriptor which needs to be zeroed out for the keep alive frame. This makes the earlier REG_WRITE redundant, so it can be removed. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
* / wireless: Use eth_<foo>_addr instead of memsetJoe Perches2015-03-03
|/ | | | | | | | | | | | Use the built-in function instead of memset. Miscellanea: Add #include <linux/etherdevice.h> where appropriate Use ETH_ALEN instead of 6 Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* wireless: use %*pb[l] to print bitmaps including cpumasks and nodemasksTejun Heo2015-02-14
| | | | | | | | | | | | printk and friends can now format bitmaps using '%*pb[l]'. cpumask and nodemask also provide cpumask_pr_args() and nodemask_pr_args() respectively which can be used to generate the two printf arguments necessary to format the specified cpu/nodemask. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: "John W. Linville" <linville@tuxdriver.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Merge tag 'wireless-drivers-next-for-davem-2015-02-07' of ↵David S. Miller2015-02-09
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next Major changes: iwlwifi: * more work for new devices (4165 / 8260) * cleanups / improvemnts in rate control * fixes for TDLS * major statistics work from Johannes - more to come * improvements for the fw error dump infrastructure * usual amount of small fixes here and there (scan, D0i3 etc...) * add support for beamforming * enable stuck queue detection for iwlmvm * a few fixes for EBS scan * fixes for various failure paths * improvements for TDLS Offchannel wil6210: * performance tuning * some AP features brcm80211: * rework some code in SDIO part of the brcmfmac driver related to suspend/resume that were found doing stress testing * in PCIe part scheduling of worker thread needed to be relaxed * minor fixes and exposing firmware revision information to user-space, ie. ethtool. mwifiex: * enhancements for change virtual interface handling * remove coupling between netdev and FW supported interface combination, now conversion from any type of supported interface types to any other type is possible * DFS support in AP mode ath9k: * fix calibration issues on some boards * Wake-on-WLAN improvements ath10k: * add support for qca6174 hardware * enable RX batching to reduce CPU load Conflicts: drivers/net/wireless/rtlwifi/pci.c Conflict resolution is to get rid of the 'end' label and keep the rest. Signed-off-by: David S. Miller <davem@davemloft.net>
| * ath9k: Delete an unnecessary check before the function call "relay_close"Markus Elfring2015-02-06
| | | | | | | | | | | | | | | | | | | | The relay_close() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Choose correct rate for 2GHz channelSujith Manoharan2015-02-06
| | | | | | | | | | | | | | | | | | Set the transmit rate for the keep-alive frames as 1M/CCK when the current channel is in the 2GHz band. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Clear TSF2 properlySujith Manoharan2015-02-06
| | | | | | | | | | | | | | | | | | Chips in the AR9003 family have a second TSF, which needs to be cleared when putting the card to sleep. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Program AR_WA correctlySujith Manoharan2015-02-06
| | | | | | | | | | | | | | | | | | Setting the required configuration in the PCIE WorkAround register needs to be done after all the WoW parameters have been set. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Fix issues with WoW enableSujith Manoharan2015-02-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch addresses several issues with the ath9k_hw_wow_enable() routine: * The usage of set/clr variables is removed. Writing the required values to registers is cleaner. * The shift value of 28 for the contention window field in AR_WOW_PATTERN is incorrect, change it to 27. * Disabling Keep Alive needs to be done based on the LINK_CHANGE option. This is done unconditionally now, fix this. * The workaround for the D1/D3 issue is required only for AR9462. * The bitfield for enabling pattern matching for packets less than 256 bytes has expanded for new chips, handle this accordingly. * General cleanup. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Register correct WOW details with mac80211Sujith Manoharan2015-02-06
| | | | | | | | | | | | | | | | | | Since the number of user patterns is higher for newer chips, make sure that this is registered during initialization. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Add support for more WOW patternsSujith Manoharan2015-02-06
| | | | | | | | | | | | | | | | | | | | Newer chips like WB222, WB335 support more than 8 user-configurable patterns. This patch adds support for it by setting up the correct HW registers. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Fix max pattern checkSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | | | Since the maximum number of configurable patterns is chip-specific, use the HW capability instead of a fixed value for checking if a free pattern slot is available. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Cleanup reg_wow.hSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | * Remove unnecessary comments. * Remove unused macros. * Indent the macros. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Remove incorrect register macrosSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | These macros are applicable to pre-AR9003 chips and the addresses are different for the AR9003 family. Since they are unused anyway, remove them. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Move WOW registers to reg_wow.hSujith Manoharan2015-02-03
| | | | | | | | | | Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Register max WOW patternsSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | Since the number of patterns that can be configured in the HW is higher for newer chips, store the chip-specific value in ath9k_hw_wow. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Add a HW structure for WOWSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | This can be used to hold the WOW state in ath9k_hw. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Simplify user pattern configurationSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | There is no need to allocate a new structure and free it for every user pattern, instead use local variables. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Add a debugfs file for WOWSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | This can be used to force WOW for cards that are not present in the supported PCI ID list. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Remove ath9k_hw_wow_event_to_stringSujith Manoharan2015-02-03
| | | | | | | | | | | | | | Printing the value of the wakeup status is sufficient. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Remove unused BMISS processingSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | | | The various variables tracking bmiss interrupts are not really used anywhere except in a debug message. Remove them since they have no functional purpose. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Check WOW triggers properlySujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | | | This patch makes sure that valid WOW triggers are present before trying to suspend the device. Also, introduce and use ATH_OP_WOW_ENABLED to bypass PCI suspend and clear it in resume(). Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Fix wow init/deinitSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | | | | | | | Registering the card as a wakeup source needs to be done once, during initialization. When the WOW configuration changes, the card's status as wakeup source needs to be changed too and this is done via the set_wakeup() callback. Also, make sure the device is removed properly using ath9k_deinit_wow(). Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Check multi-channel context for WOWSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | If CONFIG_ATH9K_CHANNEL_CONTEXT is enabled, check whether multiple contexts are active and if so, return 1 without enabling WOW since we don't support it in this case. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Check early for multi-vif/STA conditionsSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | | | If multiple interfaces are active or there is no associated station interface, bail out early and return 1 so that mac80211 can proceed with the normal suspend routine. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Remove redundant device_can_wakeup() checkSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | WOW capability is registered with mac80211 only when the device has the ability to wakeup, so there is no need to check in the suspend() routine. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Return early for error conditionsSujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | | | Do not try to cancel work instances and ANI when the device is not present or WOW triggers are not configured. Bail out early and use ath_err() for such error conditions. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Remove ATH9K_HW_WOW_DEVICE_CAPABLESujith Manoharan2015-02-03
| | | | | | | | | | | | | | | | | | Enabling WOW based on the chip is incorrect since it needs to be done for specific sub-devices which have proper platform support. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Enable manual peak detect calibrationSujith Manoharan2015-01-29
| | | | | | | | | | | | | | | | | | | | | | | | On some AR955x/QCA953x boards, noise floor calibration gets stuck and the cause is a hardware/BB issue. To fix this, peak detect calibration in the HW is disabled and is done in the driver instead. There a few differences with the calibration routine for older chips like AR9331. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Set correct peak detect thresholdSujith Manoharan2015-01-29
| | | | | | | | | | | | | | The value is different for PCOEM cards and AR955x/AR953x. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
| * ath9k: Fix manual peak calibration initializationSujith Manoharan2015-01-29
| | | | | | | | | | | | | | | | The LNA gain setting override needs to be done only for AR9330 and PCOEM chips. Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>