kernel/kernel-generic.git
12 years agoMerge branch 'master' into for-davem
John W. Linville [Thu, 12 Apr 2012 18:25:14 +0000 (14:25 -0400)]
Merge branch 'master' into for-davem

Conflicts:
drivers/net/wireless/iwlwifi/iwl-testmode.c
net/wireless/nl80211.c

12 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless
John W. Linville [Thu, 12 Apr 2012 17:49:28 +0000 (13:49 -0400)]
Merge branch 'master' of git://git./linux/kernel/git/linville/wireless

12 years agort2x00: do not generate seqno in h/w if QOS is disabled
Stanislaw Gruszka [Mon, 2 Apr 2012 11:21:06 +0000 (13:21 +0200)]
rt2x00: do not generate seqno in h/w if QOS is disabled

This is workaround H/W or F/W bug, see in code comments. Without the fix
ping can receive duplicated ICMP frames while associated with legacy AP.

Reported-by: Walter Goldens <goldenstranger@yahoo.com>
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agonet/wireless: ipw2x00: remove ssid_context struct
Stanislav Yakovlev [Sat, 7 Apr 2012 21:31:21 +0000 (17:31 -0400)]
net/wireless: ipw2x00: remove ssid_context struct

Driver does not use it any more.

Signed-off-by: Stanislav Yakovlev <stas.yakovlev@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agonet/wireless: ipw2x00: remove unused libipw_measurement_report struct
Stanislav Yakovlev [Sat, 7 Apr 2012 08:44:40 +0000 (04:44 -0400)]
net/wireless: ipw2x00: remove unused libipw_measurement_report struct

and all referenced structs and corresponding enums because the driver
does not use it.

Note: keep libipw_info_element struct since it is still in use.

Signed-off-by: Stanislav Yakovlev <stas.yakovlev@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agocfg80211: add channel switch notify event
Thomas Pedersen [Fri, 6 Apr 2012 20:35:47 +0000 (13:35 -0700)]
cfg80211: add channel switch notify event

The firmware may decide to switch channels while already beaconing, e.g.
in response to a cfg80211 connect request on a different vif. Add this
event to notify userspace when an AP or GO interface has successfully
migrated to a new channel, so it can update its configuration
accordingly.

Signed-off-by: Thomas Pedersen <c_tpeder@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath5k: Remove extraneous statements from ath5k_hw_proc_4word_tx_status and ath5k_hw_p...
Qasim Javed [Fri, 6 Apr 2012 01:40:15 +0000 (20:40 -0500)]
ath5k: Remove extraneous statements from ath5k_hw_proc_4word_tx_status and ath5k_hw_proc_2word_status.

Signed-off-by: Qasim Javed <qasimj@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agocfg80211/mac80211: enable proper device_set_wakeup_enable handling
Johannes Berg [Wed, 4 Apr 2012 13:05:25 +0000 (15:05 +0200)]
cfg80211/mac80211: enable proper device_set_wakeup_enable handling

In WoWLAN, we only get the triggers when we actually get
to suspend. As a consequence, drivers currently don't
know that the device should enable wakeup. However, the
device_set_wakeup_enable() API is intended to be called
when the wakeup is enabled, not later when needed.

Add a new set_wakeup() call to cfg80211 and mac80211 to
allow drivers to properly call device_set_wakeup_enable.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agowireless: Remove unnecessary ; from while (0) macros
Joe Perches [Tue, 3 Apr 2012 21:46:49 +0000 (14:46 -0700)]
wireless: Remove unnecessary ; from while (0) macros

Semicolons are not necessary after macros that end in while (0).
Remove them.

Simplify the macros with tests of
do { if (foo>size) memset1; else memset2;} while (0);
to a single line memset(,,min_t(size_t, foo, size))

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Arend van Spriel <arend@broadcom.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Acked-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath9k: Add more recv stats.
Ben Greear [Tue, 3 Apr 2012 16:18:59 +0000 (09:18 -0700)]
ath9k: Add more recv stats.

This adds counters in various places that can drop packets on
rx without otherwise incrementing a counter.  It also counts
some non-error cases, such as becons and fragments received.

Should help with figuring out where packets are (and are not)
dropped.

Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath9k: Add tx-failed counter.
Ben Greear [Tue, 3 Apr 2012 16:16:55 +0000 (09:16 -0700)]
ath9k: Add tx-failed counter.

This counts any failure during getting packets into
the DMA buffers, including out-of-memory, etc.

Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath9k: update to DFS pattern detector interface
Zefir Kurtisi [Tue, 3 Apr 2012 15:15:51 +0000 (17:15 +0200)]
ath9k: update to DFS pattern detector interface

Follow updates in DFS pattern detector interface:
a) use given pulse event structure
b) adapt to boolean return value of add_pulse()

Signed-off-by: Zefir Kurtisi <zefir.kurtisi@neratec.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath9k: add DFS pattern detector instance to ath_softc
Zefir Kurtisi [Tue, 3 Apr 2012 15:15:50 +0000 (17:15 +0200)]
ath9k: add DFS pattern detector instance to ath_softc

Signed-off-by: Zefir Kurtisi <zefir.kurtisi@neratec.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath9k: add DFS pattern detector
Zefir Kurtisi [Tue, 3 Apr 2012 15:15:49 +0000 (17:15 +0200)]
ath9k: add DFS pattern detector

This adds a DFS pattern detector to ath9k. It is fed with pulse events
by the radar pulse detector and reports in place whether a pattern
was detected. On detection, the result is reported as radar event to
the DFS management component in the upper layer.

Currently the ETSI DFS domain is supported with detector lines for
the patterns defined by EN-301-893 v1.5.1. Support for FCC and JP
will be added gradually.

To include the pattern detector, ath9k must be built with support
for DFS certified config flag set (CONFIG_ATH9K_DFS_CERTIFIED).

Signed-off-by: Zefir Kurtisi <zefir.kurtisi@neratec.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: clean up an ieee80211_do_open error path
Johannes Berg [Tue, 3 Apr 2012 12:45:54 +0000 (14:45 +0200)]
mac80211: clean up an ieee80211_do_open error path

Eliad's comment prompted me to look closer at
the error paths in ieee80211_do_open() and I
found one that should use the error labels.

Also add a comment about the clear_bit since
in many error cases the bit hasn't been set.

Cc: Eliad Peller <eliad@wizery.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: add improved HW queue control
Johannes Berg [Tue, 3 Apr 2012 14:28:50 +0000 (16:28 +0200)]
mac80211: add improved HW queue control

mac80211 currently only supports one hardware queue
per AC. This is already problematic for off-channel
uses since if we go off channel while the BE queue
is full and then try to send an off-channel frame
the frame will never go out. This will become worse
when we support multi-channel since then a queue on
one channel might be full, but we have to stop the
software queue for all channels. That is obviously
not desirable.

To address this problem allow drivers to register
more hardware queues, and allow them to map them to
virtual interfaces. When they stop a hardware queue
the corresponding AC software queues on the correct
interfaces will be stopped as well. Additionally,
there's an off-channel queue to solve that problem
and a per-interface after-DTIM beacon queue. This
allows drivers to manage software queues closer to
how the hardware works.

Currently, there's a limit of 16 hardware queues.
This may or may not be sufficient, we can adjust it
as needed.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: add explicit monitor interface if needed
Johannes Berg [Tue, 3 Apr 2012 12:35:57 +0000 (14:35 +0200)]
mac80211: add explicit monitor interface if needed

The queue mapping redesign that I'm planning to do
will break pure injection unless we handle monitor
interfaces explicitly. One possible option would
be to have the driver tell mac80211 about monitor
mode queues etc., but that would duplicate the API
since we already need to have queue assignments
handled per virtual interface.

So in order to solve this, have a virtual monitor
interface that is added whenever all active vifs
are monitors. We could also use the state of one
of the monitor interfaces, but managing that would
be complicated, so allocate separate state.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: manage AP netdev carrier state
Johannes Berg [Tue, 3 Apr 2012 08:24:00 +0000 (10:24 +0200)]
mac80211: manage AP netdev carrier state

The AP netdev is really only active when beaconing, so
manage the carrier state accordingly. Also do that for
VLAN interfaces enslaved to a given AP interface.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: Check basic rates when peering
Ashok Nagarajan [Tue, 3 Apr 2012 04:21:22 +0000 (21:21 -0700)]
mac80211: Check basic rates when peering

Section 13.2.3 of IEEE 80211s standard requires BSSBasicRateSet of mesh nodes
to be identical to establish peer link.

Signed-off-by: Ashok Nagarajan <ashok@cozybit.com>
Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: Modify sta_get_rates to give basic rates
Ashok Nagarajan [Tue, 3 Apr 2012 04:21:21 +0000 (21:21 -0700)]
mac80211: Modify sta_get_rates to give basic rates

Signed-off-by: Ashok Nagarajan <ashok@cozybit.com>
Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: Indicate basic rates when adding rate IEs
Ashok Nagarajan [Tue, 3 Apr 2012 04:21:20 +0000 (21:21 -0700)]
mac80211: Indicate basic rates when adding rate IEs

Basic rates are added with supported rates IE and extended supported
rates IE.

Signed-off-by: Ashok Nagarajan <ashok@cozybit.com>
Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: Use mandatory rates as basic rates when starting mesh
Ashok Nagarajan [Tue, 3 Apr 2012 04:21:19 +0000 (21:21 -0700)]
mac80211: Use mandatory rates as basic rates when starting mesh

Signed-off-by: Ashok Nagarajan <ashok@cozybit.com>
Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agort2x00: configure different txdesc parameters for non HT channel
Stanislaw Gruszka [Wed, 4 Apr 2012 14:15:33 +0000 (16:15 +0200)]
rt2x00: configure different txdesc parameters for non HT channel

This is needed when we are concted to non 11n AP.

Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoNFC: Fix the LLCP Tx fragmentation loop
Samuel Ortiz [Tue, 10 Apr 2012 17:43:03 +0000 (19:43 +0200)]
NFC: Fix the LLCP Tx fragmentation loop

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agortlwifi: Add missing DMA buffer unmapping for PCI drivers
Larry Finger [Mon, 26 Mar 2012 15:48:20 +0000 (10:48 -0500)]
rtlwifi: Add missing DMA buffer unmapping for PCI drivers

In https://bugzilla.kernel.org/show_bug.cgi?id=42976, a system with driver
rtl8192se used as an AP suffers from "Out of SW-IOMMU space" errors. These
are caused by the DMA buffers used for beacons never being unmapped.

This bug was also reported at
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/961618

Reported-and-Tested-by: Da Xue <da@lessconfused.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agortlwifi: Preallocate USB read buffers and eliminate kalloc in read routine
Larry Finger [Mon, 19 Mar 2012 20:44:31 +0000 (15:44 -0500)]
rtlwifi: Preallocate USB read buffers and eliminate kalloc in read routine

The current version of rtlwifi for USB operations uses kmalloc to
acquire a 32-bit buffer for each read of the device. When
_usb_read_sync() is called with the rcu_lock held, the result is
a "sleeping function called from invalid context" BUG. This is
reported for two cases in https://bugzilla.kernel.org/show_bug.cgi?id=42775.
The first case has the lock originating from within rtlwifi and could
be fixed by rearranging the locking; however, the second originates from
within mac80211. The kmalloc() call is removed from _usb_read_sync()
by creating a ring buffer pointer in the private area and
allocating the buffer data in the probe routine.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org> [This version good for 3.3+ - different patch for 3.2 - 2.6.39]
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoteam: add missed "statics"
Jiri Pirko [Tue, 10 Apr 2012 05:15:46 +0000 (05:15 +0000)]
team: add missed "statics"

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoteam: ab: walk through port list non-rcu
Jiri Pirko [Tue, 10 Apr 2012 05:15:45 +0000 (05:15 +0000)]
team: ab: walk through port list non-rcu

Since team->lock is being held, _rcu variant make no sense.

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoteam: add user_linkup and user_linkup_enabled per-port option
Jiri Pirko [Tue, 10 Apr 2012 05:15:44 +0000 (05:15 +0000)]
team: add user_linkup and user_linkup_enabled per-port option

Allows userspace to setup linkup for ports. Default is to take linkup
directly from ethtool state.

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoteam: add bool option type
Jiri Pirko [Tue, 10 Apr 2012 05:15:43 +0000 (05:15 +0000)]
team: add bool option type

Add another (hopefully last) option type. Use NLA_FLAG to implement
that.

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoteam: add support for per-port options
Jiri Pirko [Tue, 10 Apr 2012 05:15:42 +0000 (05:15 +0000)]
team: add support for per-port options

This patch allows to create per-port options. That becomes handy for all
sorts of stuff, for example for userspace driven link-state, 802.3ad
implementation and so on.

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agobatman-adv: add bridge loop avoidance compile option
Simon Wunderlich [Sun, 22 Jan 2012 19:00:27 +0000 (20:00 +0100)]
batman-adv: add bridge loop avoidance compile option

The define CONFIG_BATMAN_ADV_BLA switches the bridge loop avoidance
on - skip it, and the bridge loop avoidance is not compiled in.

This is useful if binary size should be saved or the feature is
not needed.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: form groups in the bridge loop avoidance
Simon Wunderlich [Sun, 22 Jan 2012 19:00:26 +0000 (20:00 +0100)]
batman-adv: form groups in the bridge loop avoidance

backbone gateways may be part of the same LAN, but participate
in different meshes. With this patch, backbone gateways form groups by
applying the groupid of another backbone gateway if it is higher. After
forming the group, they only accept messages from backbone gateways of
the same group.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: drop STP over batman
Simon Wunderlich [Sun, 22 Jan 2012 19:00:25 +0000 (20:00 +0100)]
batman-adv: drop STP over batman

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: add broadcast duplicate check
Simon Wunderlich [Sun, 22 Jan 2012 19:00:24 +0000 (20:00 +0100)]
batman-adv: add broadcast duplicate check

When multiple backbone gateways relay the same broadcast from the
backbone into the mesh, other nodes in the mesh may receive this
broadcast multiple times. To avoid this, the crc checksums of
received broadcasts are recorded and new broadcast packets with
the same content may be dropped if received by another gateway.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: don't let backbone gateways exchange tt entries
Simon Wunderlich [Sun, 22 Jan 2012 19:00:23 +0000 (20:00 +0100)]
batman-adv: don't let backbone gateways exchange tt entries

As the backbone gateways are connected to the same backbone, they
should announce the same clients on the backbone non-exclusively.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: allow multiple entries in tt_global_entries
Simon Wunderlich [Sat, 22 Oct 2011 18:12:51 +0000 (20:12 +0200)]
batman-adv: allow multiple entries in tt_global_entries

as backbone gateways will all independently announce the same clients,
also the tt global table must be able to hold multiple originators per
client entry.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: export claim tables through debugfs
Simon Wunderlich [Sun, 22 Jan 2012 19:00:21 +0000 (20:00 +0100)]
batman-adv: export claim tables through debugfs

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: make bridge loop avoidance switchable
Simon Wunderlich [Sun, 22 Jan 2012 19:00:20 +0000 (20:00 +0100)]
batman-adv: make bridge loop avoidance switchable

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: add basic bridge loop avoidance code
Simon Wunderlich [Sun, 22 Jan 2012 19:00:19 +0000 (20:00 +0100)]
batman-adv: add basic bridge loop avoidance code

This second version of the bridge loop avoidance for batman-adv
avoids loops between the mesh and a backbone (usually a LAN).

By connecting multiple batman-adv mesh nodes to the same ethernet
segment a loop can be created when the soft-interface is bridged
into that ethernet segment. A simple visualization of the loop
involving the most common case - a LAN as ethernet segment:

node1  <-- LAN  -->  node2
  |                   |
wifi   <-- mesh -->  wifi

Packets from the LAN (e.g. ARP broadcasts) will circle forever from
node1 or node2 over the mesh back into the LAN.

With this patch, batman recognizes backbone gateways, nodes which are
part of the mesh and backbone/LAN at the same time. Each backbone
gateway "claims" clients from within the mesh to handle them
exclusively. By restricting that only responsible backbone gateways
may handle their claimed clients traffic, loops are effectively
avoided.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: remove old bridge loop avoidance code
Simon Wunderlich [Sun, 22 Jan 2012 19:00:18 +0000 (20:00 +0100)]
batman-adv: remove old bridge loop avoidance code

The functionality is to be replaced by an improved implementation,
so first clean up.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: encourage batman to take shorter routes by changing the default hop penalty
Marek Lindner [Fri, 27 Jan 2012 15:11:55 +0000 (23:11 +0800)]
batman-adv: encourage batman to take shorter routes by changing the default hop penalty

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: Remove declaration of only locally used functions
Sven Eckelmann [Sun, 5 Feb 2012 17:55:22 +0000 (18:55 +0100)]
batman-adv: Remove declaration of only locally used functions

Signed-off-by: Sven Eckelmann <sven@narfation.org>
Acked-by: Antonio Quartulli <ordex@autistici.org>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: Replace bitarray operations with bitmap
Sven Eckelmann [Sat, 4 Feb 2012 16:34:52 +0000 (17:34 +0100)]
batman-adv: Replace bitarray operations with bitmap

bitarray.c consists mostly of functionality that is already available as part
of the standard kernel API. batman-adv could use architecture optimized code
and reduce the binary size by switching to the standard functions.

Signed-off-by: Sven Eckelmann <sven@narfation.org>
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agobatman-adv: use ETH_ALEN instead of hardcoded numeric constants
Antonio Quartulli [Mon, 30 Jan 2012 19:59:17 +0000 (20:59 +0100)]
batman-adv: use ETH_ALEN instead of hardcoded numeric constants

In packet.h the numeric constant 6 is used instead of the more portable ETH_ALEN
define. This patch substitute any hardcoded value with such define.

Signed-off-by: Antonio Quartulli <ordex@autistici.org>
Acked-by: Sven Eckelmann <sven@narfation.org>
12 years agobatman-adv: clean up Kconfig
Antonio Quartulli [Sat, 31 Mar 2012 13:10:33 +0000 (16:10 +0300)]
batman-adv: clean up Kconfig

Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agoMAINTAINERS: add additional maintainer for net/batman-adv
Antonio Quartulli [Mon, 2 Apr 2012 12:56:29 +0000 (14:56 +0200)]
MAINTAINERS: add additional maintainer for net/batman-adv

Add myself as maintainer for net/batman-adv as announced by Marek Linder

Signed-off-by: Antonio Quartulli <ordex@autistici.org>
12 years agob43: claim support for IBSS RSN
Antonio Quartulli [Sat, 31 Mar 2012 21:35:40 +0000 (00:35 +0300)]
b43: claim support for IBSS RSN

The driver now claims to support IBSS/RSN. Group key configuration in hardware
is skipped. Software encryption is used for multicast communications.

Signed-off-by: Antonio Quartulli <ordex@autistici.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years ago{nl,cfg}80211: Support for mesh synchronization
Javier Cardona [Sat, 31 Mar 2012 18:31:33 +0000 (11:31 -0700)]
{nl,cfg}80211: Support for mesh synchronization

Report Toffset to userspace.
Let userspace select the mesh synchronization method.

Signed-off-by: Marco Porsch <marco.porsch@s2005.tu-chemnitz.de>
Signed-off-by: Pavel Zubarev <pavel.zubarev@gmail.com>
Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: Implement mesh synchronization framework
Javier Cardona [Sat, 31 Mar 2012 18:31:32 +0000 (11:31 -0700)]
mac80211: Implement mesh synchronization framework

This patch adds MBSS extensible synchronization framework (Sec.
13.13.2 of IEEE Std. 802.11-2012).

The framework is implemented via an ops table which defines the
following functions:

    rx_bcn_presp() - this is called every time a mesh beacon is
received.
    adjust_tbtt() - this is called immediately before a beacon is about
to be transmitted.

The default neighbor offset synchronization defined in the standard is
implemented.  We also provide template functions for vendor specific
methods.

When neighbor offset synchronization is active (which is the default)
mesh neighbors in the same MBSS will track timing offsets to each other
and compensate clock drift.

In our tests we observed that this mesh synchronization implementation
successfully corrected drifts between stations of ~2PPM while
introducing a jitter of ~20us.

It is also possible to test this framework on mac80211_hwsim simulated
phys to see how it behaves under different topologies, over poor links,
etc.

Signed-off-by: Marco Porsch <marco.porsch@s2005.tu-chemnitz.de>
Signed-off-by: Pavel Zubarev <pavel.zubarev@gmail.com>
Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: Allow tsf increments via debugfs
Javier Cardona [Sat, 31 Mar 2012 18:31:31 +0000 (11:31 -0700)]
mac80211: Allow tsf increments via debugfs

Reading and writing back the tsf value via tsf is too slow if one wants
to make small increments to this timer.  With this change you can use
the syntax "+=<some value>" or "-=<some value>" to add or substract a
value from the tsf counter.

Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211_hwsim: Fill timestamp beacon at the time it is transmitted
Javier Cardona [Sat, 31 Mar 2012 18:31:30 +0000 (11:31 -0700)]
mac80211_hwsim: Fill timestamp beacon at the time it is transmitted

Generate more acurate tsf values in hwsim by setting the tsf value on
trasmitted beacons immediately before they are moved to the rx path.
Also, adjust the beacon timestamp to be the time at which the first byte
of the timestamp is transmitted.

With these changes the observed tsf offset between two hwsim/mesh peers
is 0 (unless the offset is modified via debugfs)

Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: sanity check for null SSID
Stanislaw Gruszka [Thu, 29 Mar 2012 14:30:41 +0000 (16:30 +0200)]
mac80211: sanity check for null SSID

While associated we should never have empty SSID, but life can be full
of surprises, and is allways better to print a warning than crash.

Before memcpy() in ieee80211_probereq_get() check ssid_len instead of
ssid pointer, sice pointer it always passed by "ssidie + 2" expression
to send probe functions, so practically never can be NULL.

Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: use IEEE80211_NUM_ACS
Johannes Berg [Wed, 28 Mar 2012 09:04:29 +0000 (11:04 +0200)]
mac80211: use IEEE80211_NUM_ACS

When comparing hw->queues to determine if the
device is QoS capable, use IEEE80211_NUM_ACS
instead of just 4.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: lazily stop queues in add_pending
Johannes Berg [Wed, 28 Mar 2012 09:04:28 +0000 (11:04 +0200)]
mac80211: lazily stop queues in add_pending

When adding pending SKBs there's no need to
stop all queues, we only need to stop those
that we're adding frames to. Implement that
by lazily stopping a queue as we add an SKB.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: debounce queue stop/wake
Johannes Berg [Wed, 28 Mar 2012 09:04:27 +0000 (11:04 +0200)]
mac80211: debounce queue stop/wake

When the queue status changes we need to do a fair
bit of work, so ignore no-op changes early.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: decouple # of netdev queues from HW queues
Johannes Berg [Wed, 28 Mar 2012 09:04:26 +0000 (11:04 +0200)]
mac80211: decouple # of netdev queues from HW queues

When we get more hardware queues, we'll still want
to only have netdev queues per AC, so set it up in
that way. If the hardware doesn't support QoS (by
not supporting at least 4 queues) the netdevs get
a single queue only (this is no change in behavior
as there are no drivers with 2 or 3 queues today.)

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: refuse TX queue configuration on non-QoS HW
Johannes Berg [Wed, 28 Mar 2012 09:04:25 +0000 (11:04 +0200)]
mac80211: refuse TX queue configuration on non-QoS HW

Drivers that don't support QoS also don't support
setting up their ACs, catch that early. While at
it, remove the input check since cfg80211 does it
now.

Also fix up the restart code to not try to set up
the queues in this case.

Finally also change the tx_conf array to have
IEEE80211_NUM_ACS entries instead of # of queues
since that's what it really needs.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agocfg80211/nl80211: clarify TX queue API
Johannes Berg [Wed, 28 Mar 2012 09:04:24 +0000 (11:04 +0200)]
cfg80211/nl80211: clarify TX queue API

With the plan to change mac80211's queue API to
not map ACs to queues 1:1, it seems necessary to
clarify some APIs that act on ACs rather than on
queues to spell that out explicitly. Do this.

Also verify that the AC number given is valid.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: remove antenna_sel_tx TX info field
Johannes Berg [Wed, 28 Mar 2012 09:04:23 +0000 (11:04 +0200)]
mac80211: remove antenna_sel_tx TX info field

This field is never set to anything non-zero in
mac80211, so we should be able to remove it.
Unfortunately though, the iwlwifi and iwlegacy
drivers use it for their internal TX status
processing (which shouldn't be using the rate
control API to start with), so add a new field
"status.antenna" for them, at least for now.

In the future, I plan to use the new field to
hold the hardware queue, while the SKB's queue
mapping holds the AC.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: notify driver of rate control updates
Johannes Berg [Fri, 30 Mar 2012 06:43:32 +0000 (08:43 +0200)]
mac80211: notify driver of rate control updates

Devices that have internal rate control need to be
notified when the bandwidth or SMPS state changes
just like external rate control algorithms get a
notification now.

Add this notification and clarify the change bits
while at it, the HT_CHANGED bit really meant only
bandwidth changed.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: remove queue stop on rate control update
Johannes Berg [Wed, 28 Mar 2012 08:58:38 +0000 (10:58 +0200)]
mac80211: remove queue stop on rate control update

We currently stop the queue when changing the rate
control between 20/40 MHz in the BSS. This seems to
have been necessary when we actually changed the
channel, but now that we just update the station it
doesn't seem right any more. Remove it.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: remove channel type argument from rate_update
Johannes Berg [Wed, 28 Mar 2012 08:58:37 +0000 (10:58 +0200)]
mac80211: remove channel type argument from rate_update

The channel type argument to the rate_update()
callback isn't really the correct way to give
the rate control algorithm about the desired
RX bandwidth of the peer.

Remove this argument, and instead update the
STA capabilities with 20/40 appropriately. The
SMPS update done by this callback works in the
same way, so this makes the callback cleaner.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: set HT channel before association
Johannes Berg [Wed, 28 Mar 2012 08:58:36 +0000 (10:58 +0200)]
mac80211: set HT channel before association

Changing the channel type during operation is
confusing to some drivers and will be hard to
handle in multi-channel scenarios. Instead of
changing the channel, set it to the right HT
channel before authenticating/associating and
don't change it -- just update the 20/40 MHz
restrictions in rate control as needed when
changed by the AP.

This also fixes a problem that Paul missed in
his fix for the "regulatory makes us deaf"
issue -- when we couldn't use 40 MHz we still
associated saying we were using 40 MHz, which
could in similarly broken APs make us never
even connect successfully.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: use AC constants
Johannes Berg [Tue, 27 Mar 2012 12:18:40 +0000 (14:18 +0200)]
mac80211: use AC constants

Use the AC constants instead of hard-coding
the numbers with comments.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: inline ieee80211_add_pending_skbs
Johannes Berg [Tue, 27 Mar 2012 12:18:39 +0000 (14:18 +0200)]
mac80211: inline ieee80211_add_pending_skbs

This is a trivial wrapper function, inline it.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: make ieee80211_downgrade_queue static
Johannes Berg [Tue, 27 Mar 2012 12:18:38 +0000 (14:18 +0200)]
mac80211: make ieee80211_downgrade_queue static

There's no reason for it to not be static.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: clean up uAPSD TX code
Johannes Berg [Tue, 27 Mar 2012 12:18:37 +0000 (14:18 +0200)]
mac80211: clean up uAPSD TX code

Clean up the code formatting and also replace
the constant 0 by IEEE80211_AC_VO.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: fix mesh TX coding style
Johannes Berg [Tue, 27 Mar 2012 12:18:36 +0000 (14:18 +0200)]
mac80211: fix mesh TX coding style

Fix bad indentation & pointless if nesting.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomwifiex: don't use IEEE80211_MAX_QUEUES
Johannes Berg [Tue, 27 Mar 2012 12:07:59 +0000 (14:07 +0200)]
mwifiex: don't use IEEE80211_MAX_QUEUES

IEEE80211_MAX_QUEUES is an internal mac80211 value,
it is not guaranteed to be always 4. The firmware
API in mwifiex almost certainly doesn't care about
mac80211 changing though, so mwifiex shouldn't use
this value.

Maybe it should use IEEE80211_NUM_ACS instead and
that is what I'm doing here as at least that value
will probably never change, but maybe it should
have its own define instead.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Acked-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agomac80211: don't always advertise remain-on-channel
Johannes Berg [Mon, 26 Mar 2012 16:47:18 +0000 (18:47 +0200)]
mac80211: don't always advertise remain-on-channel

Not all devices are really capable of implementing
remain-on-channel, even if it is implemented in SW,
as they can't necessarily deal with channel changes
while associated.

Remove the WIPHY_FLAG_HAS_REMAIN_ON_CHANNEL and add
it only if either the driver has remain_on_channel
implemented in the driver/device.

Also add it to all drivers that advertise P2P right
now since those definitely have to have it working.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Acked-by: Luciano Coelho <coelho@ti.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agortlwifi: Add missing DMA buffer unmapping for PCI drivers
Larry Finger [Mon, 26 Mar 2012 15:48:20 +0000 (10:48 -0500)]
rtlwifi: Add missing DMA buffer unmapping for PCI drivers

In https://bugzilla.kernel.org/show_bug.cgi?id=42976, a system with driver
rtl8192se used as an AP suffers from "Out of SW-IOMMU space" errors. These
are caused by the DMA buffers used for beacons never being unmapped.

This bug was also reported at
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/961618

Reported-and-Tested-by: Da Xue <da@lessconfused.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: Add pr_fmt
Joe Perches [Mon, 26 Mar 2012 15:27:40 +0000 (08:27 -0700)]
iwlwifi: Add pr_fmt

Prefix dmesg output with "iwlwifi: " by
adding #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: fix unused variable warning
Oliver Hartkopp [Sun, 25 Mar 2012 06:43:24 +0000 (08:43 +0200)]
iwlwifi: fix unused variable warning

In the case of disabled CONFIG_IWLWIFI_DEBUGFS option the compiler complains
about the unused variable 'img'. Fix this by moving the 'img' definition.

Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Acked-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath5k: Introduce _ath5k_printk to reduce code/text
Joe Perches [Mon, 19 Mar 2012 00:30:53 +0000 (17:30 -0700)]
ath5k: Introduce _ath5k_printk to reduce code/text

Macros can be converted to functions to reduce overall object size.

Convert the ATH5K_PRINTK macro to use _ath5k_printk.

Allyesconfig size is reduced ~10%

$ size drivers/net/wireless/ath/ath5k/built-in.o*
   text    data     bss     dec     hex filename
 211557    2032   40672  254261   3e135 drivers/net/wireless/ath/ath5k/built-in.o.new
 235412    2032   47296  284740   45844 drivers/net/wireless/ath/ath5k/built-in.o.old

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoath: Add and use pr_fmt, convert printks to pr_<level>
Joe Perches [Mon, 19 Mar 2012 00:30:52 +0000 (17:30 -0700)]
ath: Add and use pr_fmt, convert printks to pr_<level>

Use a more current logging style.
Make sure all output is prefixed appropriately.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
David S. Miller [Tue, 10 Apr 2012 18:30:45 +0000 (14:30 -0400)]
Merge git://git./linux/kernel/git/davem/net

12 years agoRevert "ath9k: fix going to full-sleep on PS idle"
Sujith Manoharan [Tue, 10 Apr 2012 06:56:11 +0000 (12:26 +0530)]
Revert "ath9k: fix going to full-sleep on PS idle"

This reverts commit c1afdaff90538ef085b756454f12b29575411214.

Users have reported connection failures in 3.3.1 and suspend/resume
failures in 3.4-rcX. Revert this commit for now - PS IDLE can be
fixed in a clean manner later on.

Cc: stable@vger.kernel.org
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agort2x00: Fix rfkill_polling register function.
Chen, Chien-Chia [Thu, 29 Mar 2012 10:21:47 +0000 (18:21 +0800)]
rt2x00: Fix rfkill_polling register function.

  Move rt2x00rfkill_register(rt2x00dev) to rt2x00lib_probe_dev
  function. It fixes of starting rfkill_poll function at the
  right time if sets hard rfkill block and reboot. rt2x00mac_rfkill_poll
  should be starting before bringing up the wireless interface.

Signed-off-by: Chen, Chien-Chia <machen@suse.com>
Acked-by: Helmut Schaa <helmut.schaa@googlemail.com>
CC: Kevin Chou <kevin.chou@mediatek.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agobcma: fix build error on MIPS; implicit pcibios_enable_device
Paul Gortmaker [Mon, 26 Mar 2012 00:02:55 +0000 (20:02 -0400)]
bcma: fix build error on MIPS; implicit pcibios_enable_device

The following is seen during allmodconfig builds for MIPS:

drivers/bcma/driver_pci_host.c:518:2: error: implicit declaration
of function 'pcibios_enable_device' [-Werror=implicit-function-declaration]
cc1: some warnings being treated as errors
make[3]: *** [drivers/bcma/driver_pci_host.o] Error 1

Most likey introduced by commit 49dc9577155576b10ff79f0c1486c816b01f58bf

    "bcma: add PCIe host controller"

Add the header instead of implicitly assuming it will be present.
Sounds like a good idea, but that alone doesn't fix anything.

The real problem is that the Kconfig has settings related to whether
PCI is possible, i.e.

  config BCMA_HOST_PCI_POSSIBLE
        bool
        depends on BCMA && PCI = y
        default y

  config BCMA_HOST_PCI
        bool "Support for BCMA on PCI-host bus"
        depends on BCMA_HOST_PCI_POSSIBLE

...but what is missing is that BCMA_DRIVER_PCI_HOSTMODE doesn't
have any dependencies on the above.  Add one.

CC: Hauke Mehrtens <hauke@hauke-m.de>
CC: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Acked-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agowiznet: Fix Kconfig dependencies.
David S. Miller [Tue, 10 Apr 2012 13:25:46 +0000 (09:25 -0400)]
wiznet: Fix Kconfig dependencies.

Both drivers need to depend upon HAS_IOMEM, otherwise we
get a build failure on platforms like S390.

All the driver specific config options need to depend upon
the drivers themselves.

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoiwlwifi: split POWER_PMI status bit
Don Fry [Thu, 15 Mar 2012 20:27:06 +0000 (13:27 -0700)]
iwlwifi: split POWER_PMI status bit

Move the POWER_PMI to the op_mode where it is changed.  The trans needs
to check it frequently, so shadow the status in the trans and update it
in trans when it infrequently changes.

Signed-off-by: Don Fry <donald.h.fry@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move FW_ERROR to priv
Don Fry [Thu, 15 Mar 2012 20:27:05 +0000 (13:27 -0700)]
iwlwifi: move FW_ERROR to priv

The op_mode should check for FW_ERROR before calling send_cmd.  This
removes the need to test for FW_ERROR in the trans layer.

Signed-off-by: Don Fry <donald.h.fry@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: remove firmware info from iwl_shared
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:27:04 +0000 (13:27 -0700)]
iwlwifi: remove firmware info from iwl_shared

With error logging now completely handled in
the op_mode, the transport layer does not
need to know information about the loaded
firmware.

Remove this state information from the
iwl_shared data structure.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move iwl_get_single_channel_number and mark it static
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:27:03 +0000 (13:27 -0700)]
iwlwifi: move iwl_get_single_channel_number and mark it static

iwl_get_single_channel_number is used only in
iwl-scan.c, move it there and mark it static.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move iwl_full_rxon_required and mark it static
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:27:02 +0000 (13:27 -0700)]
iwlwifi: move iwl_full_rxon_required and mark it static

iwl_full_rxon_required is used only in
iwl-agn-rxon.c. Move it there and mark it
static.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move iwl_check_rxon_cmd and mark it static
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:27:01 +0000 (13:27 -0700)]
iwlwifi: move iwl_check_rxon_cmd and mark it static

iwl_check_rxon_cmd is used only in
iwl-agn-rxon.c. Move it there and mark it
static.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move iwl_set_rxon_hwcrypto and mark it static
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:27:00 +0000 (13:27 -0700)]
iwlwifi: move iwl_set_rxon_hwcrypto and mark it static

iwl_set_rxon_hwcrypto is used only in
iwl-agn-rxon.c. Move it there and mark it
static.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: Move iwl_send_rxon_timing and make it static
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:26:59 +0000 (13:26 -0700)]
iwlwifi: Move iwl_send_rxon_timing and make it static

iwl_send_rxon_timing is used only in
iwl-agn-rxon.c, move it there and mark it
static.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move iwl_init_geos to iwl-agn.c
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:26:58 +0000 (13:26 -0700)]
iwlwifi: move iwl_init_geos to iwl-agn.c

This is used only in one file, move it there
and make it static.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move ucode_type from shared to op_mode
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:26:57 +0000 (13:26 -0700)]
iwlwifi: move ucode_type from shared to op_mode

This variable holds the ucode currently
running on the device; which is determined by
op_mode, so move this parameter there.

Also, the name of the variable is a bit
misleading, so rename it to cur_ucode.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move ucode error log reporting to op_mode
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:26:56 +0000 (13:26 -0700)]
iwlwifi: move ucode error log reporting to op_mode

Error log reporting does not belong to the
transport layer, but to the op_mode loading
the ucode, as it is the entity which knows
about the ucode loaded, and what the error
information means.

Move device logging pointers from the
transport layer to op_mode.

With this change, transport layer only
reports an error to the op_mode, which will
figure out what to do with the error. This
causes the driver to now dump out error logs
when the command queue is stuck as well.

Also, move the debugfs entry for event logs
out of the transport layer and into op_mode.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: make iwl_nic_error static
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:26:55 +0000 (13:26 -0700)]
iwlwifi: make iwl_nic_error static

iwl_nic_error is used in iwl-agn.c only, move
it there and make it static.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: use iwlagn_fw_error instead of iwl_nic_error
Meenakshi Venkataraman [Thu, 15 Mar 2012 20:26:54 +0000 (13:26 -0700)]
iwlwifi: use iwlagn_fw_error instead of iwl_nic_error

In the process, make iwlagn_fw_error
a non-static function, as it is used
by more than one file.

Signed-off-by: Meenakshi Venkataraman <meenakshi.venkataraman@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoiwlwifi: move valid_contexts to priv
Johannes Berg [Thu, 15 Mar 2012 20:26:53 +0000 (13:26 -0700)]
iwlwifi: move valid_contexts to priv

No other component is accessing it any more,
so it can move to the correct place in priv.

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>
12 years agoiwlwifi: move queue mapping out of transport
Johannes Berg [Thu, 15 Mar 2012 20:26:52 +0000 (13:26 -0700)]
iwlwifi: move queue mapping out of transport

The queue mapping is not only dynamic, it
is also dependent on the uCode, as we can
already see today with the dual-mode and
non-dual-mode being different.

Move the queue mapping out of the transport
layer and let the higher layer manage it.
Part of the transport configuration is how
to set up the queues.

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>
12 years agoiwlwifi: use scan while idle
Johannes Berg [Thu, 15 Mar 2012 20:26:51 +0000 (13:26 -0700)]
iwlwifi: use scan while idle

As idle is just a deep powersave mode for
the device, it will easily scan while idle
since that turns off powersave.

This reduces the number of commands sent
to the device when scanning.

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>
12 years agoiwlwifi: remove scan_rx_antennas
Johannes Berg [Thu, 15 Mar 2012 20:26:50 +0000 (13:26 -0700)]
iwlwifi: remove scan_rx_antennas

This is not (no longer?) used by any device
so just remove 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>
12 years agoiwlwifi: remove iq_invert config param
Johannes Berg [Thu, 15 Mar 2012 20:26:49 +0000 (13:26 -0700)]
iwlwifi: remove iq_invert config param

This is used only by 2000 class devices, but
they all use it so remove the configuration
parameter and hard-code the programming.

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>
12 years agoiwlwifi: remove support_wimax_coexist
Johannes Berg [Thu, 15 Mar 2012 20:26:48 +0000 (13:26 -0700)]
iwlwifi: remove support_wimax_coexist

There's no device using this mechanism.

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>