Ivo van Doorn [Mon, 30 Aug 2010 19:14:56 +0000 (21:14 +0200)]
rt2x00: Correctly kill beacon queue
USB devices upload their beacon and then automatically send
it out every beacon interval. However when killing a TX queue
we only kill the URB and not the actual transmission of the beacon.
This will reset the Beacon register to prevent any beacons from
being transmitted.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 30 Aug 2010 19:14:38 +0000 (21:14 +0200)]
rt2x00: Set PWR_PIN_CFG during initialization
Add PWR_PIN_CFG initialization for rt2800usb at the same point
as rt2800pci.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 30 Aug 2010 19:14:15 +0000 (21:14 +0200)]
rt2x00: Don't set unicast/BSSID masks when clearning MAC or BSSID
When configuring the MAC_ADDR or MAC_BSSID with an empty address,
the UNICAST_TO_ME_MASK and BSS_ID_MASK must also be reset to prevent
invalid interpretation of the addresses.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 30 Aug 2010 19:13:54 +0000 (21:13 +0200)]
rt2x00: Wakeup hardware before loading firmware
According to the legacy drivers the AUTOWAKEUP_CFG
register must be reset to 0 before loading the firmware.
Instead of during rt2800{pci,usb}_write_firmware it
must actually be done in rt2800_load_firmware() before
resetting the WPDMA_GLO_CFG and PWR_PIN_CFG registers.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 30 Aug 2010 19:13:30 +0000 (21:13 +0200)]
rt2x00: Validate TX status results with current data entry
Instead of printing a warning when the PID, ACK, or WCID of
an entry don't match the TX status report, we should skip the
entry to search for the entry which actually does match
the TX status data.
This reduces the number of watchdog errors on the TX queues
for rt2800usb, and seems to improve the reliability of the
TX flow a bit.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 30 Aug 2010 19:13:08 +0000 (21:13 +0200)]
rt2x00: Add rt2800_wait_csr_ready
Similar to rt2800_wait_wpdma_ready() we can add a
function to waiting until the CSR is ready. This
centralizes some additional code into rt2800lib.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Helmut Schaa [Mon, 30 Aug 2010 19:12:47 +0000 (21:12 +0200)]
rt2x00: Update rt2800 comments regarding AMPDU and PACKET_ID in TXWI
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Helmut Schaa [Mon, 30 Aug 2010 19:12:24 +0000 (21:12 +0200)]
rt2x00: Rename txentry_desc.queue -> txentry_desc.qid
Variables containing queue ids are called qid everywhere else, hence
rename the queue field in txentry_desc to qid as well.
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Felix Fietkau [Sat, 28 Aug 2010 16:21:21 +0000 (18:21 +0200)]
ath9k: fix spurious MIC failure reports
According to the hardware documentation, the MIC failure bit is only
valid if the frame was decrypted using a valid TKIP key and is not a
fragment.
In some setups I've seen hardware-reported MIC failures on an AP that
was configured for CCMP only, so it's clear that additional checks are
necessary.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Cc: stable@kernel.org
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Julia Lawall [Sat, 28 Aug 2010 15:41:06 +0000 (17:41 +0200)]
net/wireless: Remove double test
The same expression is tested twice and the result is the same each time.
The sematic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)
// <smpl>
@expression@
expression E;
@@
(
* E
|| ... || E
|
* E
&& ... && E
)
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Denis 'GNUtoo' Carikli [Fri, 27 Aug 2010 21:48:19 +0000 (23:48 +0200)]
wl1251: Fix queue stopping/waking for TX path
This patch was adapted from
06f7bc7db79fabe6b2ec16eff0f59e4acc21eb72
(from linus's linux-2.6 tree of kernel.org)
here's the original message:
The queue stopping/waking functionality was broken in a way that could
cause huge latencies in TX transfers and even cause the TX to stall in the
right circumstances. Correct these problems.
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@no-log.org>
Acked-by: Kalle Valo <kvalo@adurom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jouni Malinen [Fri, 27 Aug 2010 19:22:00 +0000 (22:22 +0300)]
mac80211: Do not generate CQM events based on first Beacon frames
The signal strength value in a single RX frame is not that reliable,
so it is better to delay start of CQM events until there is a real
average signal strength from more than a single Beacon frame
available.
Signed-off-by: Jouni Malinen <j@w1.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jouni Malinen [Fri, 27 Aug 2010 19:21:13 +0000 (22:21 +0300)]
mac80211: Fix signal strength average initialization for CQM events
The ave_beacon_signal value uses 1/16 dB unit and as such, must be
initialized with the signal level of the first Beacon frame multiplied
by 16. This fixes an issue where the initial CQM events are reported
incorrectly with a burst of events while the running average
approaches the correct value after the incorrect initialization. This
could cause user space -based roaming decision process to get quite
confused at the moment when we would like to go through authentication
and DHCP.
Cc: stable@kernel.org
Signed-off-by: Jouni Malinen <j@w1.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
John W. Linville [Tue, 31 Aug 2010 18:12:19 +0000 (14:12 -0400)]
Merge branch 'wireless-next-2.6' of git://git./linux/kernel/git/iwlwifi/iwlwifi-2.6
Johannes Berg [Fri, 27 Aug 2010 11:45:28 +0000 (13:45 +0200)]
mac80211: fix offchannel queue stop
Somebody noticed this problem, and I outlined
to them how to fix it, but haven't heard back
from them. So while I was adding the state
field I figured I could use it to fix it.
The problem, as I understand it, is that when
we go offchannel while the driver has a queue
stopped, the driver will likely start draining
the queue and then enable it while offchannel.
This in turn will enable the interface queue,
and that leads to transmitting data frames on
the wrong channel.
Fix this by keeping track of offchannel status
per interface, and not enabling the interface
queues on interfaces that are offchannel when
the driver enables a queue.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 10:35:59 +0000 (12:35 +0200)]
mac80211_hwsim: support runtime iftype changes
Add the trivial support for runtime interface
type changes to mac80211_hwsim for testing.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 10:35:58 +0000 (12:35 +0200)]
mac80211: support runtime interface type changes
Add support to mac80211 for changing the interface
type even when the interface is UP, if the driver
supports it.
To achieve this
* add a new driver callback for switching,
* split some of the interface up/down code out
into new functions (do_open/do_stop), and
* maintain an own __SDATA_RUNNING bit that will
not be set during interface type, so that any
other code doesn't use the interface.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 10:35:57 +0000 (12:35 +0200)]
mac80211: split out concurrent vif checks
Split the concurrent virtual interface checks
into a new function that can be used to check
for any given new interface type.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 10:35:56 +0000 (12:35 +0200)]
mac80211: simplify zero address checks
The libertas_tf special code for zero addresses
is a bit too complex, it compares against a stack
value instead of using is_zero_ether_addr() and
tries to update all interfaces even if just the
one that's being brought up needs to be changed.
Additionally, the repeated check for a valid MAC
address need only be done if we actually changed
it on the fly.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 10:35:55 +0000 (12:35 +0200)]
mac80211: switch to ieee80211_sdata_running
Since the introduction of ieee80211_sdata_running(),
some new code was introduced that uses netif_running()
instead. Switch all these instances over.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 10:35:54 +0000 (12:35 +0200)]
mac80211: clean up ifdown/cleanup paths
There's a lot of redundant code in mac80211's
interface cleanup/down, for example freeing
AP beacons is done both when the interface is
set DOWN as well as when it is torn down, of
which only the former has any effect.
Also, a bunch of things should be closer to
where they matter, like the MLME timers that
we should cancel when disassociating, rather
than only when the interface is set DOWN.
Clean up all this code.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 11:36:49 +0000 (13:36 +0200)]
mac80211: use subqueue helpers
There are subqueue helpers so that we don't
need to get the TX queue and then wake/stop
it, use those helpers.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 11:26:54 +0000 (14:26 +0300)]
mac80211: allow changing port control protocol
Some vendor specified mechanisms for 802.1X-style
functionality use a different protocol than EAP
(even if EAP is vendor-extensible). Support this
in mac80211 via the cfg80211 API for it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 11:26:53 +0000 (14:26 +0300)]
cfg80211: allow changing port control protocol
Some vendor specified mechanisms for 802.1X-style
functionality use a different protocol than EAP
(even if EAP is vendor-extensible). Allow setting
the ethertype for the protocol when a driver has
support for this. The default if unspecified is
EAP, of course.
Note: This is suitable only for station mode, not
for AP implementation.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 11:26:52 +0000 (14:26 +0300)]
mac80211: allow vendor specific cipher suites
Allow drivers to specify their own set of cipher
suites to advertise vendor-specific ciphers. The
driver is then required to implement hardware
crypto offload for it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 11:26:51 +0000 (14:26 +0300)]
cfg80211: allow vendor specific cipher suites
cfg80211 currently rejects all cipher suites it
doesn't know about for key length checking
purposes. This can lead to inconsistencies when
a driver advertises an algorithm that cfg80211
doesn't know about. Remove this rejection so
drivers can specify any algorithm they like.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Fri, 27 Aug 2010 09:29:24 +0000 (11:29 +0200)]
cfg80211 docbook: remove erronous !A
My previous patch erroneously included an
!A line (for some checking I am working on)
that isn't yet supported by the docbook
tools, so remove it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rajkumar Manoharan [Fri, 27 Aug 2010 06:39:00 +0000 (12:09 +0530)]
ath9k_htc: Enable ANI in associated state only
While scanning, ANI is triggered unnecessarily where sta is in
unassociated state. And cancelling ani work in ath9k_htc_stop
is not required.
Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Thu, 26 Aug 2010 11:30:27 +0000 (13:30 +0200)]
wl12xx: remove unneeded locking
With the scan callback now being callable from
any context, these unlocks/locks can go away.
This makes the code easier to understand, since
callers of these functions must no longer be
aware that the mutex may be dropped.
As Stanislaw is working on iwlwifi scanning, I
didn't change it to take advantage of the new
mac80211 semantics.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Thu, 26 Aug 2010 11:30:26 +0000 (13:30 +0200)]
mac80211: allow scan to complete from any context
The ieee80211_scan_completed() function was a frequent
source of potential deadlocks, since it is called by
drivers but may call back into drivers, so drivers had
to make sure to call it without any locks held, which
frequently lead to more complex code in drivers. Avoid
that problem by allowing the function to be called in
any context, and queueing the actual work it does.
Also update the documentation for it to indicate this.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Thu, 26 Aug 2010 11:30:25 +0000 (13:30 +0200)]
mac80211: remove unused scan expire define
Since cfg80211 manages the BSS list completely,
this define hasn't been used for a long time
and will never be used again.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Vivek Natarajan [Wed, 25 Aug 2010 14:04:52 +0000 (19:34 +0530)]
ath9k: Change the default LED pattern.
All major Atheros customers require the led to be in continuous
ON state rather than the blinking pattern.
Signed-off-by: Vivek Natarajan <vnatarajan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Bob Copeland [Wed, 25 Aug 2010 01:37:14 +0000 (21:37 -0400)]
ath5k: fix off-by-one in pilot magnitude mask
If the symbol offset is 46, it will be counted in both
the third and fourth bytes of the mask, and in this
case the shift will be negative which can pollute
high order bits in the mask. This may negatively impact
OFDM symbol detection.
Signed-off-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Dan Carpenter [Sat, 21 Aug 2010 19:24:59 +0000 (21:24 +0200)]
ath5k: re-order one of the frees on unwind
There was a small misordering here. In the original code, if we were to
go to err_free_ah then it wouldn't free the irq.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:58 +0000 (10:46 +0200)]
iwlwifi: allow using multiple contexts
We're now ready to start using multiple contexts.
We do this by keeping track of the valid interface
types per context (exclusive [ibss] and normal)
and checking which context is "free" when a new
interface is added.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:57 +0000 (10:46 +0200)]
iwlwifi: follow main beacon interval
It is necessary that the PAN context always
use the same beacon interval as the BSS
context unless it is in dual-station mode,
ie. the PAN context is a station as well,
so implement that.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:56 +0000 (10:46 +0200)]
iwlagn: always send RXON timing
The PAN context requires also getting
RXON timing when we send an unassociated
RXON in some cases.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:55 +0000 (10:46 +0200)]
iwlwifi: pass context to iwl_send_rxon_timing
Sometimes we need to send RXON timing even
when we don't have a virtual interface yet,
so pass the context and allow passing one
without a virtual interface pointer.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Fri, 27 Aug 2010 16:44:50 +0000 (09:44 -0700)]
iwlwifi: send PAN parameters
In order for the microcode to be able to handle
multiple interfaces, we need to give it the PAN
parameters that state how to allocate the time
between the two interfaces. Do this, and update
it wherever necessary.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:53 +0000 (10:46 +0200)]
iwlagn: send beacon before committing associated RXON
Newer AGN microcode requires know the beacon
before starting the AP so that it can start
beaconing right away. Implement that.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:52 +0000 (10:46 +0200)]
iwlagn: send RXON timing before associating
The PAN functionality requires us to send the
timing including a valid DTIM period to the
microcode before associating, so request this
data from mac80211 and send it to the device.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:51 +0000 (10:46 +0200)]
iwlagn: queue frames according to context
Frames for different contexts need to be put
on different queues, and multicast after DTIM
frames have a special queue yet which also
depends on the context, so put all this into
the context.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:50 +0000 (10:46 +0200)]
iwlagn: remove iw_mode check for beacon
Since we have the beacon context now, we no
longer need to rely on iw_mode but can check
the beacon context interface's type. However,
that check must be in the work item instead
due to locking constraints (mutex must be
held when dereferencing beacon_ctx pointer).
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:49 +0000 (10:46 +0200)]
iwlagn: detect PAN capability
Detect whether or not the ucode is PAN
capable and adjust the valid contexts
accordingly. To be able to do this, add
the PAN context to the array as well.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:48 +0000 (10:46 +0200)]
iwlwifi: add PAN API
Define the new host commands and notifications
REPLY_WIPAN_PARAMS
REPLY_WIPAN_RXON
REPLY_WIPAN_RXON_TIMING
REPLY_WIPAN_RXON_ASSOC
REPLY_WIPAN_QOS_PARAM
REPLY_WIPAN_WEPKEY
REPLY_WIPAN_P2P_CHANNEL_SWITCH
REPLY_WIPAN_NOA_NOTIFICATION
and their corresponding structures along with the PAN
station flag, the PAN AP sta ID and new dev types for
the second context.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:47 +0000 (10:46 +0200)]
iwlwifi: introduce beacon context
Only one context can be beaconing at a time,
but we need to track which one. Introduce a
new variable priv->beacon_ctx to do that.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:46 +0000 (10:46 +0200)]
iwlwifi: move HT configuration data into context
A lot of HT configuration semantically belongs into
the context, even if right now it will never be
different between contexts. Move it so we're better
prepared for future changes in mac80211.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:45 +0000 (10:46 +0200)]
iwlwifi: add context pointer to station
Sometimes we only pass around station
pointers but need to find the context
they belong to, so store it in there.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:44 +0000 (10:46 +0200)]
iwlwifi: store default station flags in context
Since the default context is initialised to zero,
and the default flags are zero, no more code is
needed to initialise them right now, but another
context can have different default flags.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:43 +0000 (10:46 +0200)]
iwlwifi: make hw crypto context aware
HW crypto needs to be aware of the context, and there
are different command IDs for the WEP keys per context,
so move the key tracking variables and command IDs into
the context structure.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:42 +0000 (10:46 +0200)]
iwlwifi: move AP sta ID to context
Each context needs to use a different AP sta
ID, so we need to move that into the context
struct instead of hardcoding it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:41 +0000 (10:46 +0200)]
iwlwifi: clamp scanning dwell time to all contexts
The dwell time should at least fit into all
context's beacon intervals.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:40 +0000 (10:46 +0200)]
iwlwifi: move virtual interface pointer into context
iwlwifi occasionally needs to find the virtual
interface pointer to give it to mac80211, but right
now it only keeps one. Move it into the context so
that we can keep one pointer each.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:39 +0000 (10:46 +0200)]
iwlwifi: add context into tx descriptor
In status processing we'll need to find the context
for a given frame, so add a context pointer to the
TX info for each frame.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:38 +0000 (10:46 +0200)]
iwlwifi: move QoS into context
Since mac80211 doesn't currently enable/disable
QoS per interface, we can't yet do it properly,
but we can already prepare for it and move the
QoS data and command ID into the context struct.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:37 +0000 (10:46 +0200)]
iwlwifi: contextify command sending
Some commands will have different command IDs
for different contexts, so we need to store
those IDs in the context structure and use
them instead of hardcoding the commands.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Fri, 27 Aug 2010 15:55:52 +0000 (08:55 -0700)]
iwlwifi: contextify-stations-completely
The microcode tracks stations per context, so
the driver needs to do that as well for adding,
deleting and restoring them, especially in the
implicit removal case when we send an RXON.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Fri, 27 Aug 2010 15:53:46 +0000 (08:53 -0700)]
iwlwifi: contextify broadcast station
The broadcast station ID is per context, so
add a variable for the ID in the context and
use it everywhere we previously hardcoded it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:34 +0000 (10:46 +0200)]
iwlwifi: define PAN queues/FIFOs
PAN capable microcode has a different
queue assignment (not just more queues
for PAN) due to the way multicast is
handled for AP mode.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:33 +0000 (10:46 +0200)]
iwlwifi: prepare for PAN queue/fifo assignment
PAN ucode will require a different queue assignment,
in particular queue 9 instead of 4 should be used for
commands.
This is required because the ucode will stop/start
queues 4 and 8 depending on the PAN state, since
queue 8 will be used for PAN multicast (after DTIM).
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Johannes Berg [Mon, 23 Aug 2010 08:46:32 +0000 (10:46 +0200)]
iwlwifi: initial contextification
In order to support multiple interfaces, we must move
a lot of data into per-context structures so we can
use the contexts the device offers. To start with,
this makes a lot of code context-aware, more changes
will move more things into the context structure.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Wey-Yi Guy [Tue, 24 Aug 2010 14:27:56 +0000 (07:27 -0700)]
iwlwifi: fix compile error without debugging support
Encounter compiler error when iwlwifi debugging support is
disabled, fix it.
This compiler error was introduced by the previous WiFi/BT coexist patchset.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Wed, 25 Aug 2010 12:34:01 +0000 (14:34 +0200)]
mac80211: fix mesh advertisement
When a mac80211-based driver advertises mesh mode
support, this will be advertised to userspace.
However, if mac80211 was compiled without mesh
support, then that won't actually be true. Fix
this by removing the bit for mesh if mesh isn't
compiled in.
Since this synchronizes what we advertise to
cfg80211 and actually support, it means we can
now rely on cfg80211's interface type checks
and need not check again in mac80211.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Christian Lamparter [Tue, 24 Aug 2010 21:29:05 +0000 (23:29 +0200)]
p54: better rssi->dbm conversion for longbow phys
This patch should fix the dodgy signal and noise value
reports for most longbow (p54spi) users:
e.g.: (an older tcpdump extract)
> 2.0 Mb/s 2437 MHz (0x00a0) -49dB signal -41dB noise
> 1.0 Mb/s 2437 MHz (0x00a0) 4dB signal -41dB noise
The formula is taken from stlc45xx:
http://gitorious.org/stlc45xx/mainline/blobs/master/stlc45xx.c#line1199
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Christian Lamparter [Tue, 24 Aug 2010 17:22:42 +0000 (19:22 +0200)]
mac80211: fix rcu-unsafe pointer dereference
This patch fixes a potential crash (null-pointer de-
reference) which was introduced in my previous patch:
"mac80211: AMPDU rx reorder timeout timer"
During a BA teardown, the pointer to the soon-to-be-gone
tid_ampdu_rx element will be nullified. Therefore the
release timer mechanism has to be careful not to
accidentally access the item without any RCU protection.
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Tue, 24 Aug 2010 10:15:53 +0000 (12:15 +0200)]
nl80211: fix missing nesting
commit
95a6ccbb46c70cff376684c752831c014c87029d
Author: Johannes Berg <johannes.berg@intel.com>
Date: Thu Aug 12 15:38:38 2010 +0200
cfg80211/mac80211: extensible frame processing
introduced a netlink bug that caused parsing errors
in userspace because it forgot to close a nesting,
which would advertise a nesting length of zero to
userspace, which then completely threw off parsing
and led to
Illegal nla->nla_type == 0
being printed by libnl.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Arnaud Patard (Rtp) [Mon, 23 Aug 2010 21:02:22 +0000 (23:02 +0200)]
rt2x00: fix "buffer size not provably correct" build warning
rt2x00 debugfs interface doesn't check the size of the data coming
from userspace, leading to a build warning. Fix That.
v2: return EINVAL if input is too long
Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org>
Acked-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:56:07 +0000 (19:56 +0200)]
rt2x00: Fix max TX power settings
During initialization each driver reads the default TX power
for each individual channel. However mac80211 only accepts the
maximum value (which is also handled as default value).
As a result, the TX power of the device was being limited to
the default value, which is often quite low compared to the
real maximum acceptable value.
This patch allows each driver to set the maximum value on a
per-channel basis which is forwarded to mac80211. The default
value will be preserved for now, in case we want to update
mac80211 to differentiate between the maximum and default txpower.
This fixes bug complaining about limited TX power values like:
https://bugzilla.kernel.org/show_bug.cgi?id=16358
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:55:43 +0000 (19:55 +0200)]
rt2x00: Fix channel configuration for RF3052
We missed a check for RF3052 in the config_channel
configuration function. As a result the channel is not
properly configured for RF3052 devices. This also
requires rt2800_config_channel_rf3xxx to support 5GHz
channels, so we must apply the TXPOWER_A_TO_DEV and
TXPOWER_G_TO_DEV conversions during rt2800_config_channel()
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:55:22 +0000 (19:55 +0200)]
rt2x00: Merge rt2800{pci/usb} radio enabling/disabling code to rt2800lib
The functions rt2800pci_enable_radio and rt2800usb_disable_radio are
almost equal and can be merged into rt2800lib. This reduces the number
of functions which must be exported from rt2800lib to the drivers at
the same time.
Also rt2800pci_disable_radio and rt2800usb_disable_radio are almost
equal and can be merged into rt2800lib in a similar fashion.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:55:01 +0000 (19:55 +0200)]
rt2x00: Fix rt2800 retry calculation
The retry count for a frame is calculated by the realized MCS rate
subtracting of the requested MCS rate. However during TX done reporting
we accidently override the requested MCS rate with the realized MCS
rate. This causes the retry count to be reset to 0 always, and feeding
invalid rate information into minstrel_ht.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:54:41 +0000 (19:54 +0200)]
rt2x00: Remove Q_INDEX_CRYPTO and ENTRY_OWNER_DEVICE_CRYPTO
Q_INDEX_CRYPTO and ENTRY_OWNER_DEVICE_CRYPTO where initially
added with the plan to implement hardware encryption for rt2500pci.
However there are no plans to do so anymore as the crypto
mechanism in rt2500pci is very different then any other Ralink
device.
So we can now safely remove the definitions, and don't think
about this feature anymore. :)
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:54:21 +0000 (19:54 +0200)]
rt2x00: Move direct access to queue->entries to rt2x00queue.c
All access to queue->entries through the Q_INDEX/Q_INDEX_DONE
variables must be done using spinlock protection. It is best
to manage this completely from rt2x00queue.c.
For safely looping through all entries in the queue, the function
rt2x00queue_for_each_entry is added which will walk from from a index
range in a safe manner.
This also fixes rt2x00usb which walked the entries list from
0 to length to kill each entry (killing entries must be done
from Q_INDEX_DONE to Q_INDEX to enforce TX status reporting to
occur in the correct order.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:54:02 +0000 (19:54 +0200)]
rt2x00: Reduce indenting
Cosmetic change, reduce indenting.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Mon, 23 Aug 2010 17:53:39 +0000 (19:53 +0200)]
rt2x00: Simplify arguments to rt2x00 driver callback functions
write_tx_desc shouldn't pass a rt2x00dev and skb pointer,
instead it should use the same format as other TX frame
callback functions, which is passing the data_entry pointer
which contains all the information which is needed to work
on a TX frame.
Most callers of the kick_tx_queue and kill_tx_queue already
have the data_queue pointer, so rather then sending the QID
with the given function, when the driver requests a new
pointer to the data_queue, it is more efficient to just
send the data_queue pointer directly.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:57:17 +0000 (07:57 -0700)]
iwlwifi: disable aggregation queue if stopped early
When aggregation is stopped again for some reason
before the queue we selected has drained, we will
currently leak the TX queue and keep it enabled
for aggregation. Normally this doesn't happen, so
the problem is rarely seen.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:16 +0000 (07:57 -0700)]
iwlwifi: add bt traffic load debugfs file
Add the debugfs file to show current bluetooth traffic load
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:15 +0000 (07:57 -0700)]
iwlagn: update bt status upon scan complete
Update bt status upon receive scan complete notification
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:14 +0000 (07:57 -0700)]
iwlagn: generic bt coex functions
Move bt coex functions to iwl-agn-lib.c, so those functions
can be shared by multiple wifi/bt combo devices
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:13 +0000 (07:57 -0700)]
iwlagn: set traffic load based on multiple factors
Current BT traffic load should based on the following conditions:
1. BT On/Off status
2. Channel announcement enable/disable
3. Curren traffic load report from uCode
Need to modify rate scale to down-grade from MIMO to SISO if detected
high BT traffic load. Also need to make sure not using chain "B" with high
BT traffic or if it is in "full concurrency" mode.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:12 +0000 (07:57 -0700)]
iwlagn: add bt_ch_announce module parameter
Add bt_ch_announce module parameter to enable/disable BT channel
announcement mode; default is "enable"
Based on the bt channel announcement module parameter to configure the
bt_config host command.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:11 +0000 (07:57 -0700)]
iwlagn: add additional bt related parameters
Add additional bt coex related parameters and initialize at init
time.
Thoese parameters will be used in later implementations.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:10 +0000 (07:57 -0700)]
iwlagn: parsing uart message and take actions
1. Based on uart message from uCode, re-configure BT kill ack mask
messages from uCode
2. send REPLY_BT_COEX_SCO command to uCode based on the uart frame
received from uCode
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:09 +0000 (07:57 -0700)]
iwlagn: add bt prio_boost to .cfg
Use .cfg to configure the default bt priority boost value;
the default bt priority boost is 0xf0
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:08 +0000 (07:57 -0700)]
iwlwifi: add bt_init_traffic_load as configurable parameter
Adding configurable parameter in .cfg for the initial Bluetooth traffic
load; set it to IWL_BT_COEX_TRAFFIC_LOAD_NONE for now, but can be change
for debugging or other reason.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:07 +0000 (07:57 -0700)]
iwlwifi: add debugfs to control stuck queue timer
In current implementation, stuck queue timer is fixed to 1 second. Add
debugfs file to modify the timer to enhance the flexibility:
Set the monitor_period as following:
0: disable stuck queue force reset function
1 - 60000: monitor period (1 - 60 second)
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:06 +0000 (07:57 -0700)]
iwlwifi: indicate bt_kill condition when receive tx reply
Generate log when receive tx reply with bt_kill count > 0 and
in advance bt coex mode
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:05 +0000 (07:57 -0700)]
iwlagn: wifi/bt coex configuration sequence
bt config command need to send before the init calibration command,
driver need to let uCode know that calibrations are being performed now
in order to assure antenna is not being taken to BT use during radio/dsp
reads/writes
Also, bt_coex_priorty_table command need to be send right after the
bt_config_command during init sequence. Followed by bt coex envelope
command to initialize and prepare uCode bt state machine
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:04 +0000 (07:57 -0700)]
iwlwifi: add bt full concurrency support
Adding the bluetooth full concurrency support for WiFi/BT combo devices.
Driver should configure uCode to operate in "full concurrency" mode (via
LUT) if both conditions are met:
- Antenna Coupling is more than 35dB
- WiFi Channel Inhibition Request is hornored by BT Core
Currently, there is no antenna coupling information provided by uCode;
use module parameter to specified the antenna coupling in dB.
When in "full concurrency" mode, driver need to download different LUT
to uCode while sending bt configuration command; also, driver need to
configure the device operate in 1x1 while in full concurrency mode.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:57:03 +0000 (07:57 -0700)]
iwlwifi: use antenna A only under high BT load
When bluetooth indicated high load, we should use
only antenna A in 2.4 GHz for management frames.
Add this condition to iwl_toggle_tx_ant() to make
sure it'll always be met. Note that scanning has
a separate way of forcing the antenna, because we
should scan on antenna A only regardless of BT
traffic load.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:57:02 +0000 (07:57 -0700)]
iwlwifi: Relax uCode timeout/error checking for 6000g2b
Disable plcp error checking for 6000g2b devices, with wifi/bt coex;
this got trigger too often, disable for now until finding better
trigger point.
Also extend the firmware reload timer much longer for BT coex to make sure
there are will be no mistake to reload firmware too fast and too often.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:57:01 +0000 (07:57 -0700)]
iwlagn: keep BT settings across restart
The BT SCO needs to be re-applied to the device,
while the traffic load just needs to be correct
in software.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:57:00 +0000 (07:57 -0700)]
iwlagn: disable gen2b BT coexistence in IBSS
IBSS doesn't allow for coexistence, so it
should be disabled.
Additionally, disable reacting to the BT
profile notification when in IBSS mode,
it likely won't be sent by the device to
start with though.
Also, in IBSS mode, BT coexistence isn't as fully-featured
and we must use a single antenna only. So instead of
peppering the code with new checks, simply pretend
we are in high BT traffic load, which has the needed
effect of disabling antenna B use.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:56:59 +0000 (07:56 -0700)]
iwlwifi: reset BT when going down
When we turn off the device, reset BT
data so that we don't have outdated
information when we come up again.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:56:58 +0000 (07:56 -0700)]
iwlagn: let bluetooth traffic load impact rate scale
Depending on the amount of bluetooth traffic,
using the shared antenna (antenna B) will have
adverse impact on both bluetooth and wireless
traffic. Add controls to improve the situation
by making rate scaling depend on the BT load.
When there's high bluetooth traffic load, there's
little point in trying to aggregate as BT traffic
would disrupt the aggregated frames all the time,
so simply don't start sessions then.
When BT traffic returns to lower levels, the rate
scaling will come here again automatically when
wifi traffic is high enough, and then it will be
able to successfully enable aggregation.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:56:57 +0000 (07:56 -0700)]
iwlwifi: add BT notification support for bt coex
When advanced bt coex enabled, uCode will send bt status
notification to driver, here add support for it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:56:56 +0000 (07:56 -0700)]
iwlagn: set BT IGNORE for some frames
The BT ignore bit should be set when transmitting
auth, assoc response and eap frames.
Also, scanning should set the BT ignore bit for the
probe request transmission; Note that we only use
the non-shared antenna.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:56:55 +0000 (07:56 -0700)]
iwlagn: implement advance BT config command
6000g2b hardware implements advance bluetooth coexist command,
implement base on the new API command strucutre.
Also increment the API 5 to support the advance BT/WIfi coex.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 23 Aug 2010 14:56:54 +0000 (07:56 -0700)]
iwlwifi: add 6000g2b BT coexist API
The new 6000g2b hardware requires a different
bluetooth coexist implementation on the host,
this adds the command/notification definitions
for it.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Mon, 23 Aug 2010 14:56:53 +0000 (07:56 -0700)]
iwlwifi: comments cleanup
No code or function changes, just some cleanup work for
out-of-date comments
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>