summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* ath9k_hw: remove redundant arguments to INIT_INI_ARRAYFelix Fietkau2012-07-173-505/+201
| | | | | | | | | The row/column sizes can be derived from the array argument within the macro itself, which is less error prone. In a few cases the supplied column size was actually wrong. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k_hw: fix tx gain tables for AR934xFelix Fietkau2012-07-171-6/+23
| | | | | | | Use the EEPROM information to choose the right tx gain table Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k_hw: enable ANI on AR934xFelix Fietkau2012-07-171-4/+0
| | | | | | | It has been tested and works properly Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: validate rx antenna settingsFelix Fietkau2012-07-171-1/+18
| | | | | | | | | | Many chips are not able to deal with non-consecutive rx antenna selections and respond with calibration errors, reset errors, etc. When an antenna is selected as a tx antenna, also flag it for rx to avoid chip issues. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k_hw: fall back to OTP ROM when platform data has no valid eeprom dataFelix Fietkau2012-07-171-2/+12
| | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* mwifiex: improvement in cfg80211 set_bitrate_mask handlerAmitkumar Karwar2012-07-172-34/+26
| | | | | | | | | | | | | | | This patch configures data rates to firmware using bitrate mask provided by cfg80211. Earlier we used to only update band information in this handler which will be used later for ibss network. Due to recent modifications in ibss join code we don't need to do that. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Avinash Patil <patila@marvell.com> Signed-off-by: Kiran Divekar <dkiran@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* mwifiex: add support to use basic rates in ibss join requestAmitkumar Karwar2012-07-172-75/+108
| | | | | | | | | | | | | | | In mwifiex_set_rf_channel() ibss specific flags were unnecessarily getting modified for infra and AP mode. This patch removes mwifiex_set_rf_channel() function and adds equivalant code in infra, ibss and AP path. For ibss, now we are chosing band based on channel type and basic rates provided in ibss join request. We can start ibss network in A only, B only, G only, BG, BGN, AN mode. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* mwifiex: remove unnecessary code in data rate configurationAmitkumar Karwar2012-07-177-201/+17
| | | | | | | | | | | | 1) Remove unnecessary wrapper functions. 2) Currently we don't have command to set Tx data rate, so mwifiex_rate_ioctl_set_rate_value() function and related code can be removed. 3) "ds_rate" filled by mwifiex_ret_tx_rate_cfg() is never used. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* mwifiex: remove redundant code in set channel pathAmitkumar Karwar2012-07-176-259/+2
| | | | | | | | | | | | | | | | | | | 1) Recently we removed set_channel cfg80211 handler. Also, cfg80211 blocks ibss connection requests if ibss network is already started /joined. Hence the code to restart ibss network in new channel (mwifiex_drv_change_adhoc_chan() function) becomes redundant. 2) mwifiex_bss_set_channel() function is redundant. It does some error checking and calculate adhoc start band and adhoc channel. Cfg80211 already takes care of error checking and provides correct channel information to the driver. Adhoc start band is already calculated in mwifiex_set_rf_channel() function. Other associated code is also removed in this patch. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k_hw: fix 5 GHz frequency selection on AR934x/AR955x with 25 MHz refclockFelix Fietkau2012-07-171-2/+2
| | | | | | | | The old code was an accidental copy&paste of the 2.4 GHz version, which doesn't work. Signed-off-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* rtlwifi: rtl8192de: Fix phy-based version calculationForest Bond2012-07-171-3/+3
| | | | | | | | | | | | | | | | | | | | | Commit d83579e2a50ac68389e6b4c58b845c702cf37516 incorporated some changes from the vendor driver that made it newly important that the calculated hardware version correctly include the CHIP_92D bit, as all of the IS_92D_* macros were changed to depend on it. However, this bit was being unset for dual-mac, dual-phy devices. The vendor driver behavior was modified to not do this, but unfortunately this change was not picked up along with the others. This caused scanning in the 2.4GHz band to be broken, and possibly other bugs as well. This patch brings the version calculation logic in parity with the vendor driver in this regard, and in doing so fixes the regression. However, the version calculation code in general continues to be largely incoherent and messy, and needs to be cleaned up. Signed-off-by: Forest Bond <forest.bond@rapidrollout.com> Cc: Stable <stable@vger.kernel.org> [v3.2+] Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: use temporary rate_index for error checkingJohannes Berg2012-07-171-4/+5
| | | | | | | | | | The mac80211 rate_index changed to be a u8, so can't hold the negative error value properly. Use a temporary variable for error checking. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: make CONFIG_ATH9K_DFS_CERTIFIED depend on CFG80211_CERTIFICATION_ONUSLuis R. Rodriguez2012-07-171-1/+1
| | | | | | | | | | Turns out every most standard Linux distributions enable CONFIG_EXPERT, so use the shiny new CFG80211_CERTIFICATION_ONUS which is meant by design to not be enabled by all Linux distributions. Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* Merge branch 'for-john' of ↵John W. Linville2012-07-1719-137/+432
|\ | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next
| * mac80211: go out of PS before sending disassocEliad Peller2012-07-171-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | on disassoc, ieee80211_set_disassoc() goes out of PS before indicating BSS_CHANGED_ASSOC (not sure why this is needed, but some drivers might count on the current behavior). However, it does it after sending the disassoc frame, which results in null-data frame being sent (in order to go out of ps) after we were already sent the disassoc, which is invalid. Fix it by going out of ps before sending the disassoc. Signed-off-by: Eliad Peller <eliad@wizery.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: remove regulatory_update()Luis R. Rodriguez2012-07-171-10/+2
| | | | | | | | | | | | | | | | | | | | regulatory_update() just calls wiphy_update_regulatory(). wiphy_update_regulatory() assumes you already have the reg_mutex held so just move the call within locking context and kill the superfluous regulatory_update(). Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: make regulatory_update() staticLuis R. Rodriguez2012-07-173-4/+4
| | | | | | | | | | | | | | | | | | Now that we have wiphy_regulatory_register() we can tuck away the core's regulatory_update() call there and make it static. Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: rename reg_device_remove() to wiphy_regulatory_deregister()Luis R. Rodriguez2012-07-173-5/+7
| | | | | | | | | | | | | | | | | | | | This makes it clearer what we're doing. This now makes a bit more sense given that regardless of the wiphy if the cell base station hint feature is supported we will be modifying the way the regulatory core behaves. Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: add cellular base station regulatory hint supportLuis R. Rodriguez2012-07-176-8/+171
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cellular base stations can provide hints to cfg80211 about where they think we are. This can be done for example on a cell phone. To enable these hints we simply allow them through as user regulatory hints but we allow userspace to clasify the hint as either coming directly from the user or coming from a cellular base station. This option is only available when you enable CONFIG_CFG80211_CERTIFICATION_ONUS. The base station hints themselves will not be processed by the core unless at least one device on the system supports this feature. Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: add CONFIG_CFG80211_CERTIFICATION_ONUSLuis R. Rodriguez2012-07-171-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds CONFIG_CFG80211_CERTIFICATION_ONUS which is to be used for features / code which require a bit of work on the system integrator's part to ensure that the system will still pass 802.11 regulatory certification. This option is also usable for researchers and experimenters looking to add code in the kernel without impacting compliant code. We'd use CONFIG_EXPERT alone but it seems that most standard Linux distributions are enabling CONFIG_EXPERT already. This allows us to define 802.11 specific kernel features under a flag that is intended by design to be disabled by standard Linux distributions, and only enabled by system integrators or distributions that have done work to ensure regulatory certification on the system with the enabled features. Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: fix set_regdom() to cancel requests with same alpha2Kalle Valo2012-07-171-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While adding regulatory support to ath6kl I noticed that I easily got the regulatory code confused. The way to reproduce the bug was: 1. iw reg set FI (in userspace) 2. cfg80211 calls ath6kl_reg_notify(FI) 3. ath6kl sets regdomain in firmware 4. firmware sends regdomain event to notify about the new regdomain (FI) 5. ath6kl calls regulatory_hint(FI) And this (from FI to FI transition) confuses cfg80211 and after that I only get "Pending regulatory request, waiting for it to be processed...." messages and regdomain changes won't work anymore. The reason why ath6kl calls regulatory_hint() is that firmware can change the regulatory domain by it's own, for example due to 11d IEs. I could of course workaround this in ath6kl but I think it's better to handle the case in cfg80211. The fix is pretty simple, use a different error code if the regdomain is same and then just set the request processed so that it doesn't block new requests. Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: support TX error rate CQMThomas Pedersen2012-07-175-0/+140
| | | | | | | | | | | | | | | | | | | | | | | | Let the user configure serveral TX error conection quality monitoring parameters: % error rate, survey interval, and # of attempted packets. On exceeding the TX failure rate over the given interval, the driver will send a CQM notify event with the actual TX failure rate and packets attempted. Signed-off-by: Thomas Pedersen <c_tpeder@qca.qualcomm.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * nl80211: add wdev ID as u64 as it shouldJohannes Berg2012-07-171-1/+1
| | | | | | | | | | | | | | | | In one of my previous patches I erroneously used nla_put_u32 for the wdev_id, fix that to use nla_put_u64. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * mac80211_hwsim: fix race condition with sta/vif pointersThomas Huehn2012-07-171-5/+0
| | | | | | | | | | | | | | | | | | | | info->control.sta and control.vif may only be dereferenced during the drv_tx call otherwise could lead to use-after-free bugs. Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de> [reword commit message] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * mac80211: fix tx-mgmt cookie value being left uninitializedNicolas Cavallari2012-07-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | commit "mac80211: unify SW/offload remain-on-channel" moved the cookie assignment from ieee80211_mgmt_tx() to ieee80211_start_roc_work(). But the latter is only called where offchannel is needed. If offchannel isn't needed/used, a uninitialized cookie value would be returned to userspace. This patch sets the cookie value when offchannel isn't used. Signed-off-by: Nicolas Cavallari <cavallar@lri.fr> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: reduce monitor interface trackingJohannes Berg2012-07-134-62/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Revert commit b78e8ceac23655e1e06b30aa95ab11742d1ac7c0 ("cfg80211: track monitor channel") and remove the set_monitor_enabled() callback. Due to the tracking happening in NETDEV_PRE_UP, it had introduced bugs because the monitor interface callback would be called before the device was started. It looks like there's no way to fix this, and using NETDEV_PRE_UP is broken anyway (since there's no NETDEV_UP_FAIL), so remove all that code, track interfaces in NETDEV_UP and also stop tracking the monitor channel in cfg80211. This mostly reverts to before the tracking, except that we keep the interface count tracking so that setting the monitor channel can be rejected properly. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211/mac80211: re-add get_channel operationJohannes Berg2012-07-134-7/+38
| | | | | | | | | | | | | | | | | | | | | | | | This essentially reverts commit 2e165b818456 but introduces the get_channel operation with a new wireless_dev argument so that you can retrieve the channel per interface. This is necessary as even though we can track all interface channels (except monitor) we can't track the channel type used. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * Revert "mac80211: refactor virtual monitor code"Johannes Berg2012-07-133-17/+14
| | | | | | | | | | | | | | | | | | | | This reverts commit 870d37fc22f3e40f9f23e06c581c8538fc16a2f0. This code doesn't work as cfg80211 will call set_monitor_enabled at the wrong time and it doesn't seem to be possible to fix this. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * mac80211: fix use after freeAlan Cox2012-07-131-2/+4
| | | | | | | | | | | | | | roc is destroyed then roc->started is referenced. Keep a local cache. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * nl80211: allow enabling WoWLAN without triggersJohannes Berg2012-07-121-17/+13
| | | | | | | | | | | | | | | | | | It may be desirable to use WoWLAN without triggers to keep the connection alive to the AP while suspended. Allow this use by enabling WoWLAN without triggers if no triggers were requested. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
| * cfg80211: ignore channel state for stopped AP/mesh interfacesFelix Fietkau2012-07-121-2/+9
| | | | | | | | | | | | | | | | | | | | | | Without this change, running AP + station on the same wiphy does not work since the commit "cfg80211: add channel checking for iface combinations". The stopped AP prevents the client from connecting to an AP on a different channel. Signed-off-by: Felix Fietkau <nbd@openwrt.org> [line-break commit message to < 72 chars] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* | wireless: brcm80211: use %pM to print BSSIDAndy Shevchenko2012-07-121-3/+1
| | | | | | | | | | Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | rtlwifi: rtl8192cu: Change buffer allocation for synchronous readsLarry Finger2012-07-122-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit a7959c1, the USB part of rtlwifi was switched to convert _usb_read_sync() to using a preallocated buffer rather than one that has been acquired using kmalloc. Although this routine is named as though it were synchronous, there seem to be simultaneous users, and the selection of the index to the data buffer is not multi-user safe. This situation is addressed by adding a new spinlock. The routine cannot sleep, thus a mutex is not allowed. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: Stable <stable@vger.kernel.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | rtlwifi: Remove extra argument from queue setup routineLarry Finger2012-07-123-3/+3
| | | | | | | | | | | | | | Remove unused argument hw from call to rtl_tid_to_ac(). Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | bcma: add new cores at the end of listRafał Miłecki2012-07-121-2/+2
| | | | | | | | | | | | | | | | This makes order in list more natural and fixes core->core_unit for more than 2 cores. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | bcma: add trivial GBIT MAC COMMON driverRafał Miłecki2012-07-127-6/+144
| | | | | | | | | | | | | | | | | | GMAC COMMON core is present on BCM4706 and is used for example to access board PHYs (PHYs can not be accessed directly using GBIT MAC core). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Acked-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | bcma: fix typo - reading number of slave wrappersRafał Miłecki2012-07-121-1/+1
| | | | | | | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | bcma: support alternative (BCM4706) ChipCommon core idRafał Miłecki2012-07-121-5/+12
| | | | | | | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | brcmsmac: restructure info->control.sta handling as it is goning to be ↵Thomas Huehn2012-07-123-8/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | removed soon. brcmsmac uses info->control.sta while doing ampdu aggregation. This patch changes the usage of the structure info->control.sta, as it is going to be removed soon from struct ieee80211_tx_info. This patch is a pre-requisit in order to add transmission power control (TPC) to the mac80211 subsystem. Suggested-by: Felix Fietkau <nbd@openwrt.org> Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de> Acked-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k: do not disable hardware while wow is enabledMohammed Shafi Shajakhan2012-07-121-0/+3
| | | | | | | | | | | | | | | | | | | | | | Hardware needs to be AWAKE and should maintain association with the AP to process WoW triggers any time Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k: Add WoW related mac80211 callbacksMohammed Shafi Shajakhan2012-07-122-0/+374
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | add suspend/resume/set_wakeup callbacks to the driver *suspend - bail out only if all the conditions for configuring WoW. is fine, currently multivif case is not handled - check for associated state. - map wow triggers from user space data. - add deauth/disassoc pattern and user defined pattern, for the later a list is maintained. - store the interrupt mask before suspend, enabled beacon miss interrupt for WoW. - configure WoW in the hardware by calling ath9k_hw_wow_enable. *resume - restore the interrupts based on the interrupt mask stored before suspend. - call ath9k_hw_wow_wakeup to configure/restore the hardware. - after wow wakeup clear away WoW events and query the WoW wakeup reason from the status register *set_wakeup - to call 'device_set_wakeup_enable' from cfg80211/mac80211 when wow is configured and as per Rafael/Johannnes the right way to do so rather in the driver suspend/resume call back Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath: Add Wake-on-Wireless debug maskMohammed Shafi Shajakhan2012-07-121-0/+2
| | | | | | | | | | | | | | | | | | | | | | to help the developers and users to debug/know whats happening with WoW Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k_hw: Add hardware code for WoWMohammed Shafi Shajakhan2012-07-123-0/+564
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | add a new file wow.c which takes care of the hardware code for WoW. *program the descriptors and data words to periodically send Keep Alive Frames. *program the user defined patterns/masks and pattern length in the hardware registers. *'ath9k_hw_wow_enable' is called during the drivers suspend callback which takes care of the following - tracking wow event mask (to suppress spurious wow events) - properly configure suspend/resume WAR registers - configure PCIE PM control register - configure MAC WoW registers and their timeouts - enabling wow configuration like magic packet, user patterns based on users configuration - configuring timeouts for KAL, beacon miss, aifs, slot time, backoff - create Keep Alive Pattern ('KAL') *'ath9k_hw_wow_wakeup' is called during the drivers resume callback which takes care of the following - primary task is to find the reason for wakeup from the wow status register - configure/restore AR_PCIE_PM_CTRL register - clear all WoW events - configure/restore suspend/resume WAR registers Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k_hw: INI changes for WoW for AR9002 chipsetsMohammed Shafi Shajakhan2012-07-123-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | for AR9002 family of chipsets and for WoW sleep, we reprogram the SerDes so that the PLL and CHK REQ are both enabled. this uses more power but in certain cases this is required as otherwise WoW sleep is unstable and chip may disappear. Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k: advertise supported WoW flags to upper layerMohammed Shafi Shajakhan2012-07-121-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | currently the code supports WoW triggers due to *magic packet *user defined patterns *deauth and disassoc patterns *disconnect - beacon miss, last beacon received timeout, no ack for keeep alive frames. Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k_hw: advertise WoW support for capable chipsetsMohammed Shafi Shajakhan2012-07-121-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | support WoW for all chipsets starting from AR9280, AR9285, AR9287, AR9380, AR9382, AR9485, AR9462. Really all hardware may not support WoW even though the flag is set and the WoW working depends on your laptop, BIOS apart from the hardware. Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k_hw: Add WoW hardware capability flagsMohammed Shafi Shajakhan2012-07-121-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | have seperate wow capability flags for *basic wow support *device capable of matching exact user defined pattern or de-authentication/disassoc pattern *device such AR9280 requires first four bytes for all sort of patterns Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k: Add definitions and structures to support WoWMohammed Shafi Shajakhan2012-07-122-0/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | *add structures, macros and variables for WoW, so that the driver can make use of it. *maintain a list for user enabled patterns and masks *track pattern slots for the hardware limitation on the maximum number of patterns that can be stored. *track interrupts enabled before WoW suspend, so that can be reconfigured after resume *have macros to parse user defined wow configurations to hardware code Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | ath9k_hw: Add register definitions for WoW supportMohammed Shafi Shajakhan2012-07-121-1/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | *MAC WoW registers back-off shift, MAC interrupt enable, magic packet enable, pattern match enable, aifs, slot wait period, keep alive frame failure count, beacon fail enable, beacon timeout, keep alive timeout, auto keep alive disable, keep alive fail disable and their corresponding status registers. keep alive frame delay, pattern end/byte offsets, transmit buffers for keep alive frames and storing the user patterns *Power Management Control registers pme_d3cold_vaux, host_pme_enable, aux_pwr_detect, power_state_mask, wow_pme_clear Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com> Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Cc: vadivel@qca.qualcomm.com Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com> Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* | Merge branch 'for-john' of ↵John W. Linville2012-07-128-40/+20
|\ \ | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next
OpenPOWER on IntegriCloud