Commit Graph

361386 Commits

Author SHA1 Message Date
Emmanuel Grumbach a77feb5d46 iwlwifi: mvm: don't support multi-channel inhibition
This feature is not implemented yet in firmware.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 14:17:06 +01:00
Emmanuel Grumbach 5b7e662ba7 iwlwifi: mvm: fix the {ack,cts}_kill_msk
The masks were wrong. They should be 0xffffffff when SCO,
HID or SNIFF profiles are used. They should be 0xffff0000
in any other case (default) to get a bit more throughput
when the BT profile allows for it.

Fix a debug print on the way.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 14:15:12 +01:00
Wei Yongjun f00f188f82 cfg80211: fix error return code in cfg80211_init()
Fix to return a negative error code from the error handling
case instead of 0, as returned elsewhere in this function.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 14:09:56 +01:00
Johannes Berg 217c157777 cfg80211: fix potential connection work crash
If wpa_supplicant and iw/iwconfig are used together, very
rarely the system crashes. It seems to be related to the
connection parameters not being set up, but it's not all
clear to me how this happens. In any case, checking that
the conn pointer exists here is probably a good idea.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 14:07:26 +01:00
Kalle Valo 0d4e67174b ath6kl: fix size_t printf warnings
My new tracing code for ath6kl introduced these warnings on 64-bit:

trace.h:38:1: warning: format '%d' expects argument of type 'int',
	but argument 4 has type 'size_t' [-Wformat]
trace.h:61:1: warning: format '%d' expects argument of type 'int',
	but argument 4 has type 'size_t' [-Wformat]
trace.h:84:1: warning: format '%d' expects argument of type 'int',
	but argument 6 has type 'size_t' [-Wformat]
trace.h:119:1: warning: format '%d' expects argument of type 'int',
	but argument 7 has type 'size_t' [-Wformat]
trace.h:173:1: warning: format '%d' expects argument of type 'int',
	but argument 3 has type 'size_t' [-Wformat]
trace.h:193:1: warning: format '%d' expects argument of type 'int',
	but argument 5 has type 'size_t' [-Wformat]
trace.h:221:1: warning: format '%d' expects argument of type 'int',
	but argument 5 has type 'size_t' [-Wformat]

Fix them by using %zd.

Reported-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-20 08:55:26 -04:00
Emmanuel Grumbach 2d5d50ee59 iwlwifi: dvm: don't send HCMD in restart flow
There is a race between the restart flow and the workers.
The workers are cancelled after the fw is already killed
and might send HCMD when there is fw to handle them.
Simply check that there is a fw to which the HCMD can be
sent before actually sending it.

Cc: stable@vger.kernel.org
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 12:10:57 +01:00
Emmanuel Grumbach 4620020b5d iwlwifi: set rfkill in internal state of the transport
We didn't update the internal of the PCIe transport when
we read the RFkill state directly. Fix that.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 12:09:55 +01:00
Emmanuel Grumbach cc904c7188 iwlwifi: fix length check in multi-TB HCMD
As reported by Ben Hutchings, there was a harmless issue in
the checks being done on the lengths of the TBs while
building the TFD for a multi-TB host command.

Cc: stable@vger@kernel.org
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 12:07:07 +01:00
Ilan Peer 571765c859 iwlwifi: mvm: Add beacon notification handler
Mostly for debugging purposes

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 12:02:27 +01:00
Johannes Berg 6caffd4f9d iwlwifi: mvm: suppress key error messages in AP mode
In AP mode, don't attempt to program GTKs into the
device, they're used for TX only so not needed and
programming them causes error messages. Also, in
this case and if key programming fails, avoid trying
to remove the key that isn't present later.

Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 12:02:12 +01:00
Emmanuel Grumbach b9545b48ff iwlwifi: mvm: MVM op_mode is supported on 7000 only
The code removed in this patch was used for bring up on
older NICs. No MVM capable fw will ever be released for
older NICs, so remove that code.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20 12:01:54 +01:00
Johannes Berg 3eb92f6a39 mac80211_hwsim: assign CAB queue properly on interface type change
When an interface change type, the CAB queue must be reassigned,
do this in hwsim to avoid warnings/crashes.

Reported-by: Jouni Malinen <j@w1.fi>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-18 22:14:26 +01:00
Stanislaw Gruszka 856a850afd rt2800: 5592: add more USB devices IDs
Reported-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:35 -04:00
Stanislaw Gruszka 415e3f2f7b rt2800: 5592: iq calibration for 5GHz
Based on:
RT5592_IQCalibration()

DPO_RT5572_LinuxSTA_2.6.1.3_20121022/cips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:35 -04:00
Stanislaw Gruszka 939ec51dc7 rt2800: 5592: add Kconfig
Enable support to 5592 chip.

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:35 -04:00
Stanislaw Gruszka 613c75fc4e rt2800: 5592: TXWI & RXWI descriptors size
Based on:
TXWI_STRUC
RXWI_STRUC

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/include/chip/rtmp_mac.h

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:35 -04:00
Stanislaw Gruszka 3d81535ea5 rt2800: 5592: add chip specific vgc calculations
Based on:
RT5592_ChipAGCAdjust()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:34 -04:00
Stanislaw Gruszka 8ba0ebf330 rt2800: 5592: add AGC init
Based on:
RT5592_RTMPAGCInit()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:34 -04:00
Stanislaw Gruszka 5bc2dd0646 rt2800: add write_with_rx_chain function
Based on:
AsicBBPWriteWithRxChain()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rtmp_chip.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:34 -04:00
Stanislaw Gruszka c630ccf1a1 rt2800: rearrange bbp/rfcsr initialization
This makes order of initialization of various registers similar like
on vendor driver.

Based on:
NICInitializeAsic()
RT5592LoadRFNormalModeSetup()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/common/rtmp_init.c
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chip/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:34 -04:00
Stanislaw Gruszka 8756130bf3 rt2800: 5592: add iq calibration
Based on:
GetIQCalibration()
IQCalibration()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rtmp_chip.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:33 -04:00
Stanislaw Gruszka 6803141b4f rt2800: 5592: more channel switch registers settings (BBP & GLRT)
Based on:
RT5592_ChipSwitchChannel()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:33 -04:00
Stanislaw Gruszka 4bc618fdd1 rt2800: 5592: enable rf init
Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:33 -04:00
Stanislaw Gruszka d5ae7a6bd0 rt2800: 5592: setup LDO_CFG0 when configuring channel
Based on:
RT5592_ChipSwitchChannel()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:33 -04:00
Stanislaw Gruszka c267548755 rt2800: 5592: init frequency calibration
Based on:
InitFrequencyCalibrationMode()
RT5592_ChipCap

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/common/frq_cal.c
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:32 -04:00
Stanislaw Gruszka cf084c6ae0 rt2800: 5592: initialize RF_38/39/30 registers
Based on:
RT5592LoadRFNormalModeSetup()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:32 -04:00
Stanislaw Gruszka a630afe4f8 rt2800: 5592: initialize BBP_R138 register
Based on:
RT5592LoadRFNormalModeSetup()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:32 -04:00
Stanislaw Gruszka 6e04f2530f rt2800: 5592: initalize BBP_R103 register on new revisions
Based on:
NICInitRT5592RFRegisters()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:32 -04:00
Stanislaw Gruszka d8bbf90a62 rt2800: 5592: initalize RF_R27 on older revisions
Based on:
NICInitRT5592RFRegisters()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:32 -04:00
Stanislaw Gruszka 0c9e5fb919 rt2800: 5592: RF early registers initialization
Based on:
NICInitRT5592RFRegisters()
RF5592Reg_2G_5G[]

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

This patch also merge common frequency adjustment (RF_R17 settings)
code. Further work is needed, to setup more RF/BBP/MAC registers after
that.

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:31 -04:00
Stanislaw Gruszka a4969d0d81 rt2800: 5592: common BBP initialization
Add BBP registers initialization common with other chipsets, but for now
performed only for 5592.

Based on:
NICInitBBP()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/common/rtmp_init.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:31 -04:00
Stanislaw Gruszka a7bbbe5cac rt2800: 5592: BBP registers initialization
Based on:
NICInitRT5592BbpRegisters()
NICInitBBP()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/common/rtmp_init.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:31 -04:00
Stanislaw Gruszka 7641328d5b rt2800: 5592: MAC registers initalization
Based on:
NICInitRT5592MacRegisters()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

On vendor driver we do not initialize TX_SW_CFG{1,2}. However the same
difference is between rt2x00 and vendor driver for 5390 chip.

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:31 -04:00
Stanislaw Gruszka 8f821098ce rt2800: 5592: channel config stub
Based on:
RT5592_ChipSwitchChannel()

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:31 -04:00
Stanislaw Gruszka 7848b23131 rt2800: 5592: add channels table
Based on:
RT5592_ChipSwitchChannel()
RT5592_Frequency_Plan_Xtal20M[]
RT5592_Frequency_Plan_Xtal40M[]

from:
DPO_RT5572_LinuxSTA_2.6.1.3_20121022/chips/rt5592.c

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:30 -04:00
Stanislaw Gruszka b8863f8bcc rt2800: 5592: early defines
Add basic defines for 5592 chip. It can not be enabled until
CONFIG_RT2800USB_RT55XX configuration option will be provided in the
Kconfig.

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:30 -04:00
Stanislaw Gruszka 53216d6a9a rt2800: do not crash if spec->channels is NULL
In case the spec->channels was not specified, print warning instead
of hard crash the kernel.

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Tested-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:29 -04:00
Helmut Schaa 8857d6dc77 rt2x00: Fix tx status reporting for reordered frames in rt2800pci
rt2800 hardware sometimes reorders tx frames when transmitting to
multiple BA enabled STAs concurrently.

For example a tx queue
	[ STA1 | STA2 | STA1 | STA2 ]
can result in the tx status reports
	[ STA1 | STA1 | STA2 | STA2 ]
when the hw decides to put the frames for STA1 in one AMPDU.

To mitigate this effect associate the currently processed tx status
to the first frame in the tx queue with a matching wcid.

This patch fixes several problems related to incorrect tx status
reporting. Furthermore the tx rate selection is much more stable when
communicating with multiple STAs.

Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:29 -04:00
Helmut Schaa 1dd0dbb30e rt2x00: Revert "rt2x00: remove unused argument"
This reverts commit db36f79237
since I'm going to use the data pointer that was removed in
a follow up patch.

Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:29 -04:00
Yogesh Ashok Powar 43283febfd mwifiex: cleanup VHT cap
Firmware returned VHT cap has the same format that cfg80211
expects. There is no need to parse the vht cap from the firmware
and then set it to ieee80211_sta_vht_cap. Just copying is
sufficient.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 16:38:29 -04:00
John W. Linville 345fb3f8ef Merge tag 'for-linville-20130318' of git://github.com/kvalo/ath6kl 2013-03-18 16:34:55 -04:00
Jussi Kivilinna 36ef0b473f rtlwifi: usb: add missing freeing of skbuff
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: stable@vger.kernel.org
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 15:20:38 -04:00
Bing Zhao 084c7189ac mwifiex: cancel cmd timer and free curr_cmd in shutdown process
curr_cmd points to the command that is in processing or waiting
for its command response from firmware. If the function shutdown
happens to occur at this time we should cancel the cmd timer and
put the command back to free queue.

Cc: <stable@vger.kernel.org> # 3.8
Tested-by: Marco Cesarano <marco@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 15:20:38 -04:00
Bing Zhao a3e240cacc mwifiex: skip pending commands after function shutdown
During rmmod mwifiex_sdio processing FUNC_SHUTDOWN command is
sent to firmware. Firmware expcets only FUNC_INIT once WLAN
function is shut down.

Any command pending in the command queue should be ignored and
freed.

Cc: <stable@vger.kernel.org> # 3.8
Tested-by: Daniel Drake <dsd@laptop.org>
Tested-by: Marco Cesarano <marco@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 15:20:38 -04:00
Amitkumar Karwar 00d7ea11ff mwifiex: fix race when queuing commands
Running the following script repeatedly on XO-4 with SD8787
produces command timeout and system lockup.

insmod mwifiex_sdio.ko
sleep 1
ifconfig eth0 up
iwlist eth0 scan &
sleep 0.5
rmmod mwifiex_sdio

mwifiex_send_cmd_async() is called for sync as well as async
commands. (mwifiex_send_cmd_sync() internally calls it for
sync command.)

"adapter->cmd_queued" gets filled inside mwifiex_send_cmd_async()
routine for both types of commands. But it is used only for sync
commands in mwifiex_wait_queue_complete(). This could lead to a
race when two threads try to queue a sync command with another
sync/async command simultaneously.

Get rid of global variable and pass command node as a parameter
to mwifiex_wait_queue_complete() to fix the problem.

Cc: <stable@vger.kernel.org> # 3.8
Reported-by: Daniel Drake <dsd@laptop.org>
Tested-by: Daniel Drake <dsd@laptop.org>
Tested-by: Marco Cesarano <marco@marvell.com>
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>
2013-03-18 15:20:36 -04:00
Felix Fietkau 01d4ab96d2 ath9k: limit tx path hang check to normal data queues
The beacon and multicast-buffer queues are managed by the beacon
tasklet, and the generic tx path hang check does not help in any way
here. Running it on those queues anyway can introduce some race
conditions leading to unnecessary chip resets.

Cc: stable@vger.kernel.org
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 15:20:35 -04:00
Felix Fietkau 74632d11a1 ath9k_hw: revert chainmask to user configuration after calibration
The commit 'ath9k_hw: fix calibration issues on chainmask that don't
include chain 0' changed the hardware chainmask to the chip chainmask
for the duration of the calibration, but the revert to user
configuration in the reset path runs too early.

That causes some issues with limiting the number of antennas (including
spurious failure in hardware-generated packets).

Fix this by reverting the chainmask after the essential parts of the
calibration that need the workaround, and before NF calibration is run.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Reported-by: Wojciech Dubowik <Wojciech.Dubowik@neratec.com>
Tested-by: Wojciech Dubowik <Wojciech.Dubowik@neratec.com>
Cc: stable@vger.kernel.org
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 15:20:34 -04:00
Stanislaw Gruszka 7f42ace311 iwl3945: fix length of dma buffers
commit bdb084b22d
Author: Stanislaw Gruszka <sgruszka@redhat.com>
Date:   Wed Feb 13 15:49:08 2013 +0100

    iwlegacy: more checks for dma mapping errors

broke il3945_tx_skb() dma buffer length settings, what results on
firmware errors like showed below and make 3945 device non usable.

iwl3945 0000:02:00.0: Microcode SW error detected. Restarting 0x82000008.
iwl3945 0000:02:00.0: Loaded firmware version: 15.32.2.9
iwl3945 0000:02:00.0: Start IWL Error Log Dump:
iwl3945 0000:02:00.0: Status: 0x000202E4, count: 1
iwl3945 0000:02:00.0: Desc 	Time	   asrtPC blink2 ilink1  nmiPC   Line
iwl3945 0000:02:00.0: SYSASSERT     (0x5) 0000208934 0x008B6 0x0035E 0x00320 0x00000 267
iwl3945 0000:02:00.0: Error Reply type 0x00000001 cmd

Reported-by: Zdenek Kabelac <zkabelac@redhat.com>
Reported-by: Krzysztof Kolasa <kkolasa@winsoft.pl>
Reported-by: Pedro Francisco <pedrogfrancisco@gmail.com>
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-03-18 15:20:34 -04:00
John W. Linville 8fa48cbdfb Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth 2013-03-18 15:17:11 -04:00
Johannes Berg 445ea4e83e mac80211: stop queues temporarily for flushing
Sometimes queues are flushed in the middle of
operation, which can lead to driver issues.
Stop queues temporarily, while flushing, to
avoid transmitting new packets while they are
being flushed.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-18 20:15:05 +01:00