Eric Lapuyade [Thu, 3 May 2012 12:53:20 +0000 (14:53 +0200)]
NFC: Removed addressed shdlc TODOs
The questions asked in the comments have been answered and addressed.
Signed-off-by: Eric Lapuyade <eric.lapuyade@intel.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Eric Lapuyade [Mon, 30 Apr 2012 16:21:51 +0000 (18:21 +0200)]
NFC: Prepare asynchronous error management for driver and shdlc
Signed-off-by: Eric Lapuyade <eric.lapuyade@intel.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mohammed Shafi Shajakhan [Fri, 6 Jul 2012 14:39:32 +0000 (20:09 +0530)]
ath9k: Stop the BTCOEX timers before disabling BTCOEX
Its safe to stop the BTCOEX timers 'period_timer' and
'no_stomp_timer' before disabling BTCOEX. These timers
can call ath9k_hw_btcoex_enable (or) change the BT
stomp type if they seem to be running after we had
called ath9k_hw_btcoex_disable, which is obviously
not correct.
Cc: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Cc: Bala Shanmugam <bkamatch@qca.qualcomm.com>
Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Mohammed Shafi Shajakhan [Fri, 6 Jul 2012 14:39:16 +0000 (20:09 +0530)]
ath9k: Fix MCI cleanup
We are doing MCI cleanup eventhough BTCOEX is not enabled
via module parameter. This means we do ath_mci_cleanup
though we skipped calling ath_mci_setup. Yet it does not
causes any issues now as we free the DMA buffer allocated
only when it is allocated during ath_mci_setup.
Reviewed-by: Bala Shanmugam <bkamatch@qca.qualcomm.com>
Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rafał Miłecki [Thu, 5 Jul 2012 20:07:32 +0000 (22:07 +0200)]
bcma: use custom printing functions
Having bus number printed makes it much easier to anaylze logs on
systems with more buses. For example Netgear WNDR4500 has 3 AMBA buses
in total, which makes standard log really messy.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rafał Miłecki [Thu, 5 Jul 2012 19:55:46 +0000 (21:55 +0200)]
b43: N-PHY: fix RSSI calibration
Specs were updated, change code to match it.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Arend van Spriel [Tue, 3 Jul 2012 18:46:02 +0000 (20:46 +0200)]
brcmsmac: fix brcms_c_regd_init() which crashed after 11ad patch
This patch fixes an OOPS in brcmsmac driver, which was introduced
by the 11ad patch 'cfg80211: add 802.11ad (60gHz band) support'.
The value IEEE80211_NUM_BANDS increased, which was used in the
brcms_c_regd_init() function.
Cc: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Cc: Johannes Berg <johannes.berg@intel.com>
Acked-by: Seth Forshee <seth.forshee@canonical.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:34 +0000 (19:13 +0200)]
ath9k: enable support for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:33 +0000 (19:13 +0200)]
ath9k: set 4ADDRESS bit in RX filter for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:32 +0000 (19:13 +0200)]
ath9k: enable PLL workaround for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:31 +0000 (19:13 +0200)]
ath9k: fix PLL initialization for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:30 +0000 (19:13 +0200)]
ath9k: skip internal regulator configuration for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:29 +0000 (19:13 +0200)]
ath9k: disable SYNC_HOST1_FATAL interrupts for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:28 +0000 (19:13 +0200)]
ath9k: fix RF channel frequency configuration for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:27 +0000 (19:13 +0200)]
ath9k: fix PAPRD settings for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:26 +0000 (19:13 +0200)]
ath9k: fix antenna control configuration for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:25 +0000 (19:13 +0200)]
ath9k: fix XPABIASLEVEL settings for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:24 +0000 (19:13 +0200)]
ath9k: read spur frequency information from eeprom for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:23 +0000 (19:13 +0200)]
ath9k: add mode register initialization code for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:22 +0000 (19:13 +0200)]
ath9k: add initvals for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:21 +0000 (19:13 +0200)]
ath9k: enable TX/RX data byte swap for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:20 +0000 (19:13 +0200)]
ath9k: clear pciexpress flag for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:19 +0000 (19:13 +0200)]
ath9k: add BB name string for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:18 +0000 (19:13 +0200)]
ath9k: add platform_device_id for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:17 +0000 (19:13 +0200)]
ath9k: set MAC version for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:16 +0000 (19:13 +0200)]
ath9k: define MAC version for AR9550
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gabor Juhos [Tue, 3 Jul 2012 17:13:15 +0000 (19:13 +0200)]
ath9k: define DEVID for QCA955x
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Acked-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Oskar Schirmer [Tue, 3 Jul 2012 09:31:48 +0000 (09:31 +0000)]
net/wireless: remove macro defined twice with same value
In the list of commands CMD_802_11_EEPROM_ACCESS had been
defined twice, unnecessarily, luckily with same value.
Remove one occurence.
Signed-off-by: Oskar Schirmer <oskar@scara.com>
Cc: Marcelo Tosatti <marcelo@kvack.org>
Cc: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Amitkumar Karwar [Tue, 3 Jul 2012 02:32:33 +0000 (19:32 -0700)]
mwifiex: add set_antenna handler support
This enables user to set mode of Tx/Rx path using "iw set antenna"
command. For non MIMO chips, the command will be used for selecting
specific antenna or configuring antenna diversity 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>
Rajkumar Manoharan [Sun, 1 Jul 2012 14:23:55 +0000 (19:53 +0530)]
ath9k_hw: fix AR9462 2g5g switch on full reset
On full reset, mci reset will put LNA update on 2G mode. And
Whenever 2g5g_switch is forced at the end of full reset, lna
update should not be skipped. Not doing so, is affecting WLAN
rx and causing beacon loss when BTCOEX is enabled on AR9462.
Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rajkumar Manoharan [Sun, 1 Jul 2012 14:23:54 +0000 (19:53 +0530)]
ath9k: fix power consumption on network sleep when BTCOEX is enabled
The chip is waken up for every 45ms in btcoex timer cycle to
for sharing the radio between BT and WLAN. Whenever the wlan
interface is in network sleep mode, do not schedule hw timers.
This could reduce power consumption on idle associated state.
Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rajkumar Manoharan [Sun, 1 Jul 2012 14:23:53 +0000 (19:53 +0530)]
ath9k: fix fullsleep power consumption when BTCOEX is enabled
As soon as the interface brought up, btcoex timer starts running
eventhough the interface is in idle state and WLAN chip is moved
to full sleep mode. There is no point in running btcoex timer when
the wlan interface is in sleep mode and also it might consumes
more power on WLAN idle unassociated state. So lets stop the
btcoex when wlan is idle state.
Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rajkumar Manoharan [Sun, 1 Jul 2012 14:23:52 +0000 (19:53 +0530)]
ath9k_hw: do not load noise floor readings when it is running
Noise floor calibration is performed on longcal interval and
the reading will be updated in history buffer. On rare occasions,
the previous noisefloor calibration might not be completed within
the period and trying to load nf reading will be failed. In such
situation, postpone the nf cabliration to next cycle to give
enough time to complete the calibration. This was already taken
care for ar9002 chips.
Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rajkumar Manoharan [Sun, 1 Jul 2012 14:23:51 +0000 (19:53 +0530)]
ath9k_hw: start noisefloor calibration after MCI reset
noisefloor calibration has to be loaded and started after
chip reset completion and restoring chainmask. Right now it is
being started before MCI reset completion on full reset. Fix that.
Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:45 +0000 (01:44 +0200)]
bcma: add mdelay bcma_pmu_resources_init()
This is based on code from brcmsmac.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:44 +0000 (01:44 +0200)]
bcma: add bcma_pmu_spuravoid_pllupdate()
This function is needed by brcmsmac. This code is based on code from
the Broadcom SDK.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:43 +0000 (01:44 +0200)]
bcma: remove chip ids doing nothing from PMU initialization.
The list of devices where nothing has to be done in
bcma_pmu_resources_init() and bcma_pmu_workarounds() is longer as all
the SoCs are missing there and some new devices will be added in some
time later. This patch changes the default case to just log on debug
level and also let the other devices which do not need any special
handling into the default case, instead of adding the missing 8 SoC
chip ids.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:42 +0000 (01:44 +0200)]
bcma: remove bcma_pmu_{pll,swreg}_init()
These functions are doing nothing in the current code.
I do not think we will need these function in the future as the
corresponding functions in the Broadcom SDK are just doing something
useful on chips supported by ssb or fullmac chips.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:41 +0000 (01:44 +0200)]
bcma: complete workaround for BCMA43224 and BCM4313
This code is based on the Broadcom SDK and brcmsmac.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:40 +0000 (01:44 +0200)]
bcma: add PCI ID for BCM43224
This ID was found on the PCIe wireless card on the board of a Netgear
WNDR3400 using a bcm4716. The device with this ID is identified by b43
as "Broadcom 43224 WLAN".
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:39 +0000 (01:44 +0200)]
bcma: remove fix for 4329b0 bad LPOM is detection
There is not core id with 0x4329, but at the same place in the open
source part of the Broadcom SDK is a check for some device with the
chip id of 0x4329. The device with a chip id of 0x4329 is a full mac
device, so it will never be supported by bcma, this part is running in
the firmware of the device and not on the host CPU.
This code is wrong and will never be used, so just remove it.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:38 +0000 (01:44 +0200)]
bcma: add constants for chip ids
The chip IDs are used all over bcma and no constants where defined.
This patch adds the constants and makes bcma use them.
Acked-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Hauke Mehrtens [Fri, 29 Jun 2012 23:44:37 +0000 (01:44 +0200)]
bcma: extend workaround for bcm4331
This patch is based on a recent version of the Broadcom SDK.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Thomas Huehn [Fri, 29 Jun 2012 14:43:10 +0000 (10:43 -0400)]
ath9k: fixing register bit shift values of control packets to support TPC
Some register values of bit shifts are corrected in order to support the upcoming
transmission power control (tpc) for control packets as well.
Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Mohammed Shafi Shajakhan [Fri, 29 Jun 2012 05:04:39 +0000 (10:34 +0530)]
ath9k: Fix clearing of BTCOEX flags
BTCOEX flags are set/cleared by atomic operations.
We got to do the same in ath9k_btcoex_timer_resume,
while clearing those BTCOEX flags.
Acked-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Avinash Patil [Fri, 29 Jun 2012 03:30:30 +0000 (20:30 -0700)]
mwifiex: parse WPS IEs from beacon_data
Parse WPS IEs from start_ap as well as change_beacon handlers
and set them to FW. Beacon IEs, Probe Response IEs and Assoc
Response IEs are parsed from beacon_data and set to FW with
related masks.
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>
Avinash Patil [Fri, 29 Jun 2012 03:30:29 +0000 (20:30 -0700)]
mwifiex: advertise WPS probe response offload support to cfg80211
Being a fullmac driver, mwifiex takes care of populating
beacon, probe response, association response WPS IEs to firmware.
And firmware is responsible for constructing these frames.
Advertise this to cfg80211.
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Avinash Patil [Fri, 29 Jun 2012 03:30:28 +0000 (20:30 -0700)]
mwifiex: add change_beacon cfg80211 handler
This patch adds support for change_beacon handler which is needed
for setting modified management IEs to driver and FW.
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Avinash Patil [Fri, 29 Jun 2012 03:30:27 +0000 (20:30 -0700)]
mwifiex: overwrite earlier IE buffers for new set IE request
All IE buffers are freshly supplied. In such case, there is no need
to preserve earlier buffers with same management mask and index.
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Avinash Patil [Fri, 29 Jun 2012 03:30:26 +0000 (20:30 -0700)]
mwifiex: separate IE parsing for Head/Tail IEs and beacon_ies etc
While Head/Tail IEs may contain RSN/WPA IEs which needs to be set
for all mgmt subtypes, beacon_ies, probe_resp_ies, assoc_resp_ies
are for specific mgmt subtypes. Move them to separate function.
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Avinash Patil [Fri, 29 Jun 2012 03:30:25 +0000 (20:30 -0700)]
mwifiex: pass cfg80211_beacon_data to mwifiex_set_mgmt_ie()
Pass cfg80211_beacon_data pointer instead of cfg80211_ap_settings.
While setting management IEs we only need cfg80211_beacon_data of
cfg80211_ap_settings which has Tail IE, Head IE and other IE elements.
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
John W. Linville [Mon, 9 Jul 2012 20:35:18 +0000 (16:35 -0400)]
Merge branch 'for-john' of git://git./linux/kernel/git/iwlwifi/iwlwifi-next
John W. Linville [Mon, 9 Jul 2012 20:34:39 +0000 (16:34 -0400)]
Merge branch 'for-john' of git://git.sipsolutions.net/mac80211-next
John W. Linville [Mon, 9 Jul 2012 20:34:34 +0000 (16:34 -0400)]
Merge branch 'master' of git://git./linux/kernel/git/linville/wireless
Conflicts:
net/mac80211/mlme.c
Emmanuel Grumbach [Wed, 4 Jul 2012 11:59:08 +0000 (13:59 +0200)]
iwlegacy: don't mess up the SCD when removing a key
When we remove a key, we put a key index which was supposed
to tell the fw that we are actually removing the key. But
instead the fw took that index as a valid index and messed
up the SRAM of the device.
This memory corruption on the device mangled the data of
the SCD. The impact on the user is that SCD queue 2 got
stuck after having removed keys.
Reported-by: Paul Bolle <pebolle@tiscali.nl>
Cc: stable@vger.kernel.org
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Stanislaw Gruszka [Wed, 4 Jul 2012 11:20:20 +0000 (13:20 +0200)]
iwlegacy: always monitor for stuck queues
This is iwlegacy version of:
commit
342bbf3fee2fa9a18147e74b2e3c4229a4564912
Author: Johannes Berg <johannes.berg@intel.com>
Date: Sun Mar 4 08:50:46 2012 -0800
iwlwifi: always monitor for stuck queues
If we only monitor while associated, the following
can happen:
- we're associated, and the queue stuck check
runs, setting the queue "touch" time to X
- we disassociate, stopping the monitoring,
which leaves the time set to X
- almost 2s later, we associate, and enqueue
a frame
- before the frame is transmitted, we monitor
for stuck queues, and find the time set to
X, although it is now later than X + 2000ms,
so we decide that the queue is stuck and
erroneously restart the device
Cc: stable@vger.kernel.org
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Stanislaw Gruszka [Wed, 4 Jul 2012 11:10:02 +0000 (13:10 +0200)]
rt2x00usb: fix indexes ordering on RX queue kick
On rt2x00_dmastart() we increase index specified by Q_INDEX and on
rt2x00_dmadone() we increase index specified by Q_INDEX_DONE. So entries
between Q_INDEX_DONE and Q_INDEX are those we currently process in the
hardware. Entries between Q_INDEX and Q_INDEX_DONE are those we can
submit to the hardware.
According to that fix rt2x00usb_kick_queue(), as we need to submit RX
entries that are not processed by the hardware. It worked before only
for empty queue, otherwise was broken.
Note that for TX queues indexes ordering are ok. We need to kick entries
that have filled skb, but was not submitted to the hardware, i.e.
started from Q_INDEX_DONE and have ENTRY_DATA_PENDING bit set.
From practical standpoint this fixes RX queue stall, usually reproducible
in AP mode, like for example reported here:
https://bugzilla.redhat.com/show_bug.cgi?id=828824
Reported-and-tested-by: Franco Miceli <fmiceli@plan.ceibal.edu.uy>
Reported-and-tested-by: Tom Horsley <horsley1953@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Bing Zhao [Tue, 3 Jul 2012 22:53:13 +0000 (15:53 -0700)]
mwifiex: fix Coverity SCAN CID 709078: Resource leak (RESOURCE_LEAK)
> *. CID 709078: Resource leak (RESOURCE_LEAK)
> - drivers/net/wireless/mwifiex/cfg80211.c, line: 935
> Assigning: "bss_cfg" = storage returned from "kzalloc(132UL, 208U)"
> - but was not free
> drivers/net/wireless/mwifiex/cfg80211.c:935
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Eliad Peller [Mon, 2 Jul 2012 11:42:03 +0000 (14:42 +0300)]
mac80211: destroy assoc_data correctly if assoc fails
If association failed due to internal error (e.g. no
supported rates IE), we call ieee80211_destroy_assoc_data()
with assoc=true, while we actually reject the association.
This results in the BSSID not being zeroed out.
After passing assoc=false, we no longer have to call
sta_info_destroy_addr() explicitly. While on it, move
the "associated" message after the assoc_success check.
Cc: stable@vger.kernel.org [3.4+]
Signed-off-by: Eliad Peller <eliad@wizery.com>
Reviewed-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Sasha Levin [Sat, 30 Jun 2012 09:56:47 +0000 (11:56 +0200)]
NFC: Prevent NULL deref when getting socket name
llcp_sock_getname can be called without a device attached to the nfc_llcp_sock.
This would lead to the following BUG:
[ 362.341807] BUG: unable to handle kernel NULL pointer dereference at (null)
[ 362.341815] IP: [<
ffffffff836258e5>] llcp_sock_getname+0x75/0xc0
[ 362.341818] PGD
31b35067 PUD
30631067 PMD 0
[ 362.341821] Oops: 0000 [#627] PREEMPT SMP DEBUG_PAGEALLOC
[ 362.341826] CPU 3
[ 362.341827] Pid: 7816, comm: trinity-child55 Tainted: G D W
3.5.0-rc4-next-20120628-sasha-00005-g9f23eb7 #479
[ 362.341831] RIP: 0010:[<
ffffffff836258e5>] [<
ffffffff836258e5>] llcp_sock_getname+0x75/0xc0
[ 362.341832] RSP: 0018:
ffff8800304fde88 EFLAGS:
00010286
[ 362.341834] RAX:
0000000000000000 RBX:
ffff880033cb8000 RCX:
0000000000000001
[ 362.341835] RDX:
ffff8800304fdec4 RSI:
ffff8800304fdec8 RDI:
ffff8800304fdeda
[ 362.341836] RBP:
ffff8800304fdea8 R08:
7ebcebcb772b7ffb R09:
5fbfcb9c35bdfd53
[ 362.341838] R10:
4220020c54326244 R11:
0000000000000246 R12:
ffff8800304fdec8
[ 362.341839] R13:
ffff8800304fdec4 R14:
ffff8800304fdec8 R15:
0000000000000044
[ 362.341841] FS:
00007effa376e700(0000) GS:
ffff880035a00000(0000) knlGS:
0000000000000000
[ 362.341843] CS: 0010 DS: 0000 ES: 0000 CR0:
0000000080050033
[ 362.341844] CR2:
0000000000000000 CR3:
0000000030438000 CR4:
00000000000406e0
[ 362.341851] DR0:
0000000000000000 DR1:
0000000000000000 DR2:
0000000000000000
[ 362.341856] DR3:
0000000000000000 DR6:
00000000ffff0ff0 DR7:
0000000000000400
[ 362.341858] Process trinity-child55 (pid: 7816, threadinfo
ffff8800304fc000, task
ffff880031270000)
[ 362.341858] Stack:
[ 362.341862]
ffff8800304fdea8 ffff880035156780 0000000000000000 0000000000001000
[ 362.341865]
ffff8800304fdf78 ffffffff83183b40 00000000304fdec8 0000006000000000
[ 362.341868]
ffff8800304f0027 ffffffff83729649 ffff8800304fdee8 ffff8800304fdf48
[ 362.341869] Call Trace:
[ 362.341874] [<
ffffffff83183b40>] sys_getpeername+0xa0/0x110
[ 362.341877] [<
ffffffff83729649>] ? _raw_spin_unlock_irq+0x59/0x80
[ 362.341882] [<
ffffffff810f342b>] ? do_setitimer+0x23b/0x290
[ 362.341886] [<
ffffffff81985ede>] ? trace_hardirqs_on_thunk+0x3a/0x3f
[ 362.341889] [<
ffffffff8372a539>] system_call_fastpath+0x16/0x1b
[ 362.341921] Code: 84 00 00 00 00 00 b8 b3 ff ff ff 48 85 db 74 54 66 41 c7 04 24 27 00 49 8d 7c 24 12 41 c7 45 00 60 00 00 00 48 8b 83 28 05 00 00 <8b> 00 41 89 44 24 04 0f b6 83 41 05 00 00 41 88 44 24 10 0f b6
[ 362.341924] RIP [<
ffffffff836258e5>] llcp_sock_getname+0x75/0xc0
[ 362.341925] RSP <
ffff8800304fde88>
[ 362.341926] CR2:
0000000000000000
[ 362.341928] ---[ end trace
6d450e935ee18bf3 ]---
Signed-off-by: Sasha Levin <levinsasha928@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Thomas Huehn [Fri, 29 Jun 2012 13:26:27 +0000 (06:26 -0700)]
mac80211: correct size the argument to kzalloc in minstrel_ht
msp has type struct minstrel_ht_sta_priv not struct minstrel_ht_sta.
(This incorporates the fixup originally posted as "mac80211: fix kzalloc
memory corruption introduced in minstrel_ht". -- JWL)
Reported-by: Fengguang Wu <wfg@linux.intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de>
Acked-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Wed, 4 Jul 2012 10:58:40 +0000 (12:58 +0200)]
mac80211_hwsim: add testmode code to stop/wake queues
This was useful for debugging the queue stop/wake
issues and is pretty small so let's just put it in.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Wed, 4 Jul 2012 10:49:59 +0000 (12:49 +0200)]
mac80211: fix crash with single-queue drivers
Larry (and some others I think) reported that with
single-queue drivers mac80211 crashes when waking
the queues. This happens because we allocate just
a single queue for each virtual interface in case
the driver doesn't have at least 4 queues, but the
code stopping/waking the virtual interface queues
wasn't taking this into account.
Reported-by: Larry Finger <Larry.Finger@lwfinger.net>
Tested-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Eliad Peller [Mon, 2 Jul 2012 12:08:25 +0000 (15:08 +0300)]
mac80211: always set in_reconfig=false on wakeup
If the interfaces were removed just before a restart
work was started, open_count will be 0, and most of
the reconfig work will be skipped, including the
resetting of local->in_reconfig to false.
Leaving local->inconfig = true will result in
dropping any incoming packet.
Fix it by always setting local->in_reconfig = false
(even if there are no active interfaces).
Signed-off-by: Eliad Peller <eliad@wizery.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Thu, 5 Jul 2012 19:37:05 +0000 (21:37 +0200)]
mac80211: fix debugfs default key links
Due to the way the default key links are created,
it happens that a link is left dangling:
* both unicast/multicast links are created
* unicast link is destroyed, and the links
are updated
* during this update, adding the multicast
link again fails because it is present,
destroying the debugfs pointer
* removing the multicast link won't work as
the pointer has been destroyed
Fix this by always removing the links and then
re-creating them if needed.
Reported-by: Marek Lindner <lindner_marek@yahoo.de>
Reported-by: Antonio Quartulli <ordex@autistici.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Vladimir Kondratiev [Thu, 5 Jul 2012 11:25:50 +0000 (14:25 +0300)]
cfg80211: bitrate calculation for 60g
60g band uses different from .11n MCS scheme, so bitrate
should be calculated differently
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Vladimir Kondratiev [Thu, 5 Jul 2012 11:25:49 +0000 (14:25 +0300)]
{nl,cfg}80211: support high bitrates
Until now, a u16 value was used to represent bitrate value.
With VHT bitrates this becomes too small.
Introduce a new 32-bit bitrate attribute. nl80211 will report
both the new and the old attribute, unless the bitrate doesn't
fit into the old u16 attribute in which case only the new one
will be reported.
User space tools encouraged to prefer the 32-bit attribute, if
available (since it won't be available on older kernels.)
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
[reword commit message and comments a bit]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Wed, 4 Jul 2012 11:28:18 +0000 (13:28 +0200)]
cfg80211: fix locking regression in monitor channel tracking
Michal's monitor channel tracking introduce a locking problem
as it locked the rdev lock inside the netdev notifier which
isn't allowed as we might already hold it if we get there by
removing an interface that is up.
Fix this by relying only on the RTNL to protect the interface
counters, the RTNL is always held in these code paths anyway.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Richard A. Griffiths [Thu, 28 Jun 2012 20:14:11 +0000 (13:14 -0700)]
iwlwifi: disallow log_event access if interface down
'echo 1 > log_event' generates the bogus "MAC is in deep sleep"
or "Timeout waiting for hardware access" log messages when
the interface is down, we should just disallow accessing the
device through debugfs when it is down.
Signed-off-by: Richard A. Griffiths <richardx.a.griffiths@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Fri, 29 Jun 2012 12:24:12 +0000 (14:24 +0200)]
iwlwifi: remove unneeded NULL check
There's no need to check trans for non-null
here as it has already been checked in the
caller. This fixes an smatch warning that we
check after having dereferenced it.
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Wed, 27 Jun 2012 11:18:36 +0000 (13:18 +0200)]
mac80211: add TX prepare API
Some drivers require setup before being able to send
management frames in managed mode, in particular in
multi-channel cases.
Introduce API to allow the drivers to do such setup
while being able to sleep waiting for the setup to
finish in the device. This isn't possible inside the
TX call since that can't sleep.
A future patch may also restructure the TX retry to
wait for the driver to report the frame status, as
suggested by Arik in
http://mid.gmane.org/CA+XVXffKSEL6ZQPQ98x-zO-NL2=TNF1uN==mprRyUmAaRn254g@mail.gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Tue, 3 Jul 2012 11:14:49 +0000 (13:14 +0200)]
mac80211_hwsim: fix NUM_BANDS usage
Due to the recent change of NUM_BANDS from 2 to 3 hwsim
broke. Fix the code by using the right constant but don't
support bands other than 2.4 and 5 GHz.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Thomas Huehn [Mon, 2 Jul 2012 17:46:16 +0000 (19:46 +0200)]
mac80211: reduce IEEE80211_TX_MAX_RATES
IEEE80211_TX_MAX_RATES can be reduced from 5 to 4 as there
is no current hardware supporting a rate chain with 5 multi
rate stages (mrr), so 4 mrr stages are sufficient.
The memory that is freed within the ieee80211_tx_info struct
will be used in the upcoming Transmission Power Control (TPC)
implementation.
Suggested-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de>
[reword commit message]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Mon, 2 Jul 2012 13:40:18 +0000 (15:40 +0200)]
mac80211: remove tx_frags driver callback
The implementation of tx_frags is buggy due to
not handling queue stop, and there's no driver
implementing it so remove it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Mahesh Palivela [Mon, 2 Jul 2012 11:25:12 +0000 (11:25 +0000)]
mac80211: include VHT capability IE in probe requests
Insert the VHT capability IE into probe requests.
Signed-off-by: Mahesh Palivela <maheshp@posedge.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Vladimir Kondratiev [Mon, 2 Jul 2012 06:32:35 +0000 (09:32 +0300)]
wireless: 60g protocol constants
Provide various constants as defined by the 802.11ad:
frame types, IE's, capability bits, action categories
Introduce GCMP cipher, mandatory by 802.11ad
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Vladimir Kondratiev [Mon, 2 Jul 2012 06:32:34 +0000 (09:32 +0300)]
wireless: regulatory for 60g
Add regulatory rule for the 60g band
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Vladimir Kondratiev [Mon, 2 Jul 2012 06:32:32 +0000 (09:32 +0300)]
cfg80211: add 802.11ad (60gHz band) support
Add enumerations for both cfg80211 and nl80211.
This expands wiphy.bands etc. arrays.
Extend channel <-> frequency translation to cover 60g band
and modify the rate check logic since there are no legacy
mandatory rates (only MCS is used.)
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Eliad Peller [Thu, 28 Jun 2012 12:03:13 +0000 (15:03 +0300)]
mac80211: allow calling ieee80211_ap_probereq_get() during auth/assoc
Drivers might need getting the probe request
(e.g. in order to extract the ssid) even during
auth/assoc.
Make ieee80211_ap_probereq_get() support it
by considering auth_data/assoc_data as well.
Signed-off-by: Eliad Peller <eliad@wizery.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Thu, 28 Jun 2012 16:45:38 +0000 (18:45 +0200)]
iwlwifi: fix debug message level
Debug messages should be printed using dev_dbg() not
dev_err() which requires DEBUG to be defined.
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Thu, 28 Jun 2012 14:49:29 +0000 (16:49 +0200)]
iwlwifi: add trailing newline to some messages
Some messages were missing a trailing newline, add it.
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:08 +0000 (12:47 +0200)]
cfg80211: respect iface combinations when starting operation
devlist_mtx locking is changed to accomodate changes.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:07 +0000 (12:47 +0200)]
cfg80211: add channel checking for iface combinations
.connect cannot be handled since the driver scans
and connects on its own. It is up to the driver
then to refuse a connection (with -EBUSY for
example).
Non-fixed channel IBSSes always take a single
channel resource. For example two non-fixed
channel IBSSes always take up 2
num_different_channels, even if they operate on
the same channel at a given point of time.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:06 +0000 (12:47 +0200)]
cfg80211/mac80211: remove .get_channel
We do not need it anymore since cfg80211 tracks
monitor channel and monitor channel type.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:05 +0000 (12:47 +0200)]
cfg80211: set initial monitor channel
Implements behaviour seen in mac80211. A running
monitor always has a channel - even before
.set_channel. This way we won't break current
behaviour.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:04 +0000 (12:47 +0200)]
cfg80211: track monitor channel
Make it even more obvious we support single
monitor channel. This will allow us to remove
.get_channel.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:03 +0000 (12:47 +0200)]
cfg80211: refuse to .set_monitor_channel when non-monitors are present
Having .set_monitor_channel work with non-monitor
interfaces running would make interface
combinations accounting ambiguous.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:02 +0000 (12:47 +0200)]
mac80211: refactor virtual monitor code
Use cfg80211 the new .set_monitor_enabled instead
of tracking it inside mac80211.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:01 +0000 (12:47 +0200)]
cfg80211: track monitor interfaces count
Implements .set_monitor_enabled(wiphy, enabled).
Notifies driver upon change of interface layout.
If only monitor interfaces become present it is
called with 2nd argument being true. If
non-monitor interface appears then 2nd argument
is false. Driver is notified only upon change.
This makes it more obvious about the fact that
cfg80211 supports single monitor channel. Once we
implement multi-channel we don't want to allow
setting monitor channel while other interface
types are running. Otherwise it would be ambiguous
once we start considering num_different_channels.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:47:00 +0000 (12:47 +0200)]
cfg80211: introduce cfg80211_get_chan_state
Helper function for finding out which channel is
used by a given interface.
An exclusive channel can be used only by a single
interface. This is mainly for non-fixed channel
IBSS handling.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:46:59 +0000 (12:46 +0200)]
cfg80211: track ibss fixed channel
IBSS may hop between channels. It is necessary to
account this special case when considering
interface combinations.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:46:58 +0000 (12:46 +0200)]
cfg80211: add channel tracking for AP and mesh
We need to know which channel is used by a running
AP and mesh for channel context accounting and
finding matching/active interface combination.
STA/IBSS have current_bss already which allows us
to check which channel a vif is tuned to.
Non-fixed channel IBSS can be handled with
additional changes.
Monitor mode is going to be handled differently.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:46:57 +0000 (12:46 +0200)]
cfg80211: .stop_ap when interface is going down
We'll need this for proper channel tracking (which
is going to be needed for channel context
accounting and finding matching/active interface
combination).
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Fri, 29 Jun 2012 10:46:56 +0000 (12:46 +0200)]
cfg80211: introduce cfg80211_stop_ap
This functionality will be reused when interface
is going down. Avoids code duplication. Also adds
missing wdev locking.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Amitkumar Karwar [Thu, 28 Jun 2012 02:57:59 +0000 (19:57 -0700)]
mwifiex: retrieve correct max_power information in reg_notifier handler
As we don't provide custom regulatory rules to cfg80211,
"chan->max_power" remains uninitialized (0dbm) and
"chan->max_reg_power" will contain maximum power for a channel
extracted from regulatory rules provided by CRDA; hence use
"chan->max_reg_power" in reg_notifier handler instead of
"chan->max_power" to set max_power in firmware.
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>
Amitkumar Karwar [Thu, 28 Jun 2012 02:57:58 +0000 (19:57 -0700)]
mwifiex: do not advertise custom regulatory domain capability
Since we don't support custom regulatory domains,
WIPHY_FLAG_CUSTOM_REGULATORY should not be enabled during wiphy
registration.
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>
Amitkumar Karwar [Thu, 28 Jun 2012 02:57:57 +0000 (19:57 -0700)]
mwifiex: use correct firmware command to get power limits
"priv->max_tx_power_level" and "priv->min_tx_power_level" variables
are initialized to maximum and minimum power levels supported by
hardware by sending correct firmware command.
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>
Amitkumar Karwar [Thu, 28 Jun 2012 02:57:56 +0000 (19:57 -0700)]
mwifiex: wakeup main thread to handle command queued
We miss to wakeup main thread after adding command to cmd pending
queue at follwing places. These commands are handled later when
main thread is woken up for handling an interrupt for sleep event
from firmware. This adds worst case delay of 50msec.
1) We don't wakeup main thread when asynchronous command is added
to cmd pending queue. Move queue_work() call from
mwifiex_wait_queue_complete() to mwifiex_send_cmd_async() to wakeup
main thread for sync as well as async commands.
2) Scan operation is triggered due to following reasons
a) request from user (ex. "iw scan" command)
b) Scan performed by driver internally.
In first case main thread is woken up when first scan command is
queued in cmd pending queue (we don't need to wakeup main thread for
subsequent scan commands, because they are queued in scan command
response handler), but it is not done for second case. queue_work()
is moved inside mwifiex_scan_networks() to handle both the cases.
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Felix Fietkau [Thu, 28 Jun 2012 00:33:41 +0000 (02:33 +0200)]
ath9k: de-duplicate initvals
The initvals tool from https://github.com/mcgrof/qca-swiss-army-knife has
been modified to detect identical initval tables and replace them with
macros. This patch contains the generated changes.
On MIPS this reduces the binary size by 24 KB with no runtime changes.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Felix Fietkau [Thu, 28 Jun 2012 00:33:40 +0000 (02:33 +0200)]
ath9k: update AR934x initvals to latest version
Generated using the initvals tool from the qca-swiss-army-knife repository
from https://github.com/mcgrof/qca-swiss-army-knife
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>