dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

167 Commits

Author SHA1 Message Date
John W. Linville 0d462bbb0e mwl8k: add get_survey callback in order to get channel noise
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Lennert Buytenhek <buytenh@wantstofly.org>
2010-07-29 12:46:45 -04:00
Joe Perches c96c31e499 drivers/net/wireless: Use wiphy_<level>
Standardize the logging macros used.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-07-27 15:14:13 -04:00
John W. Linville 800f65bba8 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/holtmann/bluetooth-next-2.6
Conflicts:
	drivers/net/wireless/iwlwifi/iwl-commands.h
2010-07-27 11:59:19 -04:00
John W. Linville b603742f49 mwl8k: correct/silence sparse warnings
drivers/net/wireless/mwl8k.c:1541:21: warning: incorrect type in assignment (different base types)
drivers/net/wireless/mwl8k.c:1541:21:    expected restricted __le16 [usertype] result
drivers/net/wireless/mwl8k.c:1541:21:    got int
drivers/net/wireless/mwl8k.c:1575:42:    expected unsigned short [unsigned] [usertype] cmd
drivers/net/wireless/mwl8k.c:1575:42:    got restricted __le16 [usertype] code
drivers/net/wireless/mwl8k.c:1587:50: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1587:50:    expected unsigned short [unsigned] [usertype] cmd
drivers/net/wireless/mwl8k.c:1587:50:    got restricted __le16 [usertype] code
drivers/net/wireless/mwl8k.c:1592:50: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1592:50:    expected unsigned short [unsigned] [usertype] cmd
drivers/net/wireless/mwl8k.c:1592:50:    got restricted __le16 [usertype] code
drivers/net/wireless/mwl8k.c:1845:27: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1845:27:    expected unsigned int [unsigned] [usertype] <noident>
drivers/net/wireless/mwl8k.c:1845:27:    got restricted __le32 [usertype] <noident>
drivers/net/wireless/mwl8k.c:1848:27: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1848:27:    expected unsigned int [unsigned] [usertype] <noident>
drivers/net/wireless/mwl8k.c:1848:27:    got restricted __le32 [usertype] <noident>
drivers/net/wireless/mwl8k.c:1851:27: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1851:27:    expected unsigned int [unsigned] [usertype] <noident>
drivers/net/wireless/mwl8k.c:1851:27:    got restricted __le32 [usertype] <noident>
drivers/net/wireless/mwl8k.c:1854:27: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1854:27:    expected unsigned int [unsigned] [usertype] <noident>
drivers/net/wireless/mwl8k.c:1854:27:    got restricted __le32 [usertype] <noident>
drivers/net/wireless/mwl8k.c:1857:27: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1857:27:    expected unsigned int [unsigned] [usertype] <noident>
drivers/net/wireless/mwl8k.c:1857:27:    got restricted __le32 [usertype] <noident>
drivers/net/wireless/mwl8k.c:1860:27: warning: incorrect type in argument 1 (different base types)
drivers/net/wireless/mwl8k.c:1860:27:    expected unsigned int [unsigned] [usertype] <noident>
drivers/net/wireless/mwl8k.c:1860:27:    got restricted __le32 [usertype] <noident>
drivers/net/wireless/mwl8k.c:3055:20: warning: incorrect type in assignment (different base types)
drivers/net/wireless/mwl8k.c:3055:20:    expected restricted __le16 [usertype] ht_caps
drivers/net/wireless/mwl8k.c:3055:20:    got unsigned short [unsigned] [usertype] cap

At least the last one looks like a real bug...

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Lennert Buytenhek <buytenh@wantstofly.org>
2010-07-20 16:49:42 -04:00
David S. Miller 14599f1e34 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6
Conflicts:
	drivers/net/wireless/wl12xx/wl1271.h
	drivers/net/wireless/wl12xx/wl1271_cmd.h
2010-06-11 11:34:06 -07:00
Eric Dumazet ba2d358791 drivers/net: use __packed annotation
cleanup patch.

Use new __packed annotation in drivers/net/

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2010-06-03 03:18:23 -07:00
FUJITA Tomonori 53b1b3e1f0 mwl8k: use the dma state API instead of the pci equivalents
The DMA API is preferred.

No functional change.

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Acked-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-06-02 16:02:53 -04:00
John W. Linville 83163244f8 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem
Conflicts:
	drivers/net/wireless/libertas_tf/cmd.c
	drivers/net/wireless/libertas_tf/main.c
2010-05-05 16:14:16 -04:00
John W. Linville f5c044e53a mac80211: remove deprecated noise field from ieee80211_rx_status
Also remove associated IEEE80211_HW_NOISE_DBM from ieee80211_hw_flags.

Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-04-30 15:38:13 -04:00
John W. Linville 3377d1b903 mwl8k: remove usage of deprecated noise value
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-04-28 16:48:19 -04:00
David S. Miller 871039f02f Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
	drivers/net/stmmac/stmmac_main.c
	drivers/net/wireless/wl12xx/wl1271_cmd.c
	drivers/net/wireless/wl12xx/wl1271_main.c
	drivers/net/wireless/wl12xx/wl1271_spi.c
	net/core/ethtool.c
	net/mac80211/scan.c
2010-04-11 14:53:53 -07:00
David S. Miller 4a35ecf8bf Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
	drivers/net/bonding/bond_main.c
	drivers/net/via-velocity.c
	drivers/net/wireless/iwlwifi/iwl-agn.c
2010-04-06 23:53:30 -07:00
Linus Torvalds cb4361c1dc Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (37 commits)
  smc91c92_cs: fix the problem of "Unable to find hardware address"
  r8169: clean up my printk uglyness
  net: Hook up cxgb4 to Kconfig and Makefile
  cxgb4: Add main driver file and driver Makefile
  cxgb4: Add remaining driver headers and L2T management
  cxgb4: Add packet queues and packet DMA code
  cxgb4: Add HW and FW support code
  cxgb4: Add register, message, and FW definitions
  netlabel: Fix several rcu_dereference() calls used without RCU read locks
  bonding: fix potential deadlock in bond_uninit()
  net: check the length of the socket address passed to connect(2)
  stmmac: add documentation for the driver.
  stmmac: fix kconfig for crc32 build error
  be2net: fix bug in vlan rx path for big endian architecture
  be2net: fix flashing on big endian architectures
  be2net: fix a bug in flashing the redboot section
  bonding: bond_xmit_roundrobin() fix
  drivers/net: Add missing unlock
  net: gianfar - align BD ring size console messages
  net: gianfar - initialize per-queue statistics
  ...
2010-04-06 08:34:06 -07:00
Jiri Pirko 22bedad3ce net: convert multicast list to list_head
Converts the list and the core manipulating with it to be the same as uc_list.

+uses two functions for adding/removing mc address (normal and "global"
 variant) instead of a function parameter.
+removes dev_mcast.c completely.
+exposes netdev_hw_addr_list_* macros along with __hw_addr_* functions for
 manipulation with lists on a sandbox (used in bonding and 80211 drivers)

Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2010-04-03 14:22:15 -07:00
Benjamin Larsson e5868ba10c Add a pci-id to the mwl8k driver
Signed-off-by: Benjamin Larsson <banan@ludd.ltu.se>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-03-30 15:37:25 -04:00
Tejun Heo 5a0e3ad6af include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files.  percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -> slab.h dependency is about to be removed.  Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability.  As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

  http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
  only the necessary includes are there.  ie. if only gfp is used,
  gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
  blocks and try to put the new include such that its order conforms
  to its surrounding.  It's put in the include block which contains
  core kernel includes, in the same order that the rest are ordered -
  alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
  doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
  because the file doesn't have fitting include block), it prints out
  an error message indicating which .h file needs to be added to the
  file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
   over 4000 files, deleting around 700 includes and adding ~480 gfp.h
   and ~3000 slab.h inclusions.  The script emitted errors for ~400
   files.

2. Each error was manually checked.  Some didn't need the inclusion,
   some needed manual addition while adding it to implementation .h or
   embedding .c file was more appropriate for others.  This step added
   inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
   from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
   e.g. lib/decompress_*.c used malloc/free() wrappers around slab
   APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
   editing them as sprinkling gfp.h and slab.h inclusions around .h
   files could easily lead to inclusion dependency hell.  Most gfp.h
   inclusion directives were ignored as stuff from gfp.h was usually
   wildly available and often used in preprocessor macros.  Each
   slab.h inclusion directive was examined and added manually as
   necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
   were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
   distributed build env didn't work with gcov compiles) and a few
   more options had to be turned off depending on archs to make things
   build (like ipr on powerpc/64 which failed due to missing writeq).

   * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
   * powerpc and powerpc64 SMP allmodconfig
   * sparc and sparc64 SMP allmodconfig
   * ia64 SMP allmodconfig
   * s390 SMP allmodconfig
   * alpha SMP allmodconfig
   * um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
   a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo <tj@kernel.org>
Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
2010-03-30 22:02:32 +09:00
Johannes Berg 4a6967b88a mwl8k: convert to new station add/remove callbacks
This converts mwl8k to use the new station
add/remove callbacks instead of using the
old sta_notify callback.

The new callbacks can sleep, so a lot of
code can be removed now.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Acked-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-02-22 11:21:43 -05:00
Pavel Roskin 0466236085 mwl8k: disable softirqs when accessing sta_notify_list
Use spin_[un]lock_bh in mwl8k_sta_notify().  The sta_notify handler is
required to be atomic, yet it can be called in process context, so make
sure one call won't preempt another.

Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-02-16 14:16:24 -05:00
Kalle Valo 8ccbc3b8b0 mwl8k: remove get_tx_stats() mac80211 op
get_tx_stats() will be removed from mac80211.

mwl8k used struct ieee80211_tx_queue_stats internally to track the queue
lenght. Replace struct ieee80211_tx_queue_stats with a simple len field
in struct mwl8k_tx_queue. Limit and count fields seemed to be unused.

Compile-tested only.

Cc: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Kalle Valo <kalle.valo@iki.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-02-08 16:50:59 -05:00
Johannes Berg 56007a028c mac80211: wait for beacon before enabling powersave
Because DTIM information is required for powersave
but is only conveyed in beacons, wait for a beacon
before enabling powersave, and change the way the
information is conveyed to the driver accordingly.

mwl8k doesn't currently seem to implement PS but
requires the DTIM period in a different way; after
talking to Lennert we agreed to just have mwl8k do
the parsing itself in the finalize_join work.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Acked-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-26 11:53:21 -05:00
Lennert Buytenhek a5fb297d63 mwl8k: update version number (to 0.12) and copyright
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:24 -05:00
Lennert Buytenhek ee0ddf1865 mwl8k: enable multi-BSS AP operation
As follows:
- GET_HW_SPEC is now responsible for setting
  priv->{ap,sta}_macids_supported, which are bitmasks of supported
  macids for AP and STA mode.  (Typically, STA firmware images will
  support only one macid, #0, in STA mode, and AP firmware images
  will support macids #0-7, in AP mode.)
- Our wiphy ->interfaces_modes is now set based on the non-zero-ness
  of these two bitmasks.
- We main priv->macids_used, a bitmask of which macids are currently
  in use.  ->add_interface() will assign the lowest free macid for
  this interface type as it is created, or bail out if there are no
  more free macids to assign.  ->delete_interface() will mark the
  macid as being free again.

This enables the multi-BSS code added in the previous commits.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:23 -05:00
Lennert Buytenhek aa21d0f69a mwl8k: post per-vif firmware commands as per-vif commands
SET_BEACON, SET_MAC_ADDR, BSS_START and SET_NEW_STN are the currently
supported firmware commands that are actually per-vif commands.  Use
mwl8k_post_pervif_cmd() for these commands, so that the macid of the
vif they operate on gets passed down into the firmware.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:21 -05:00
Lennert Buytenhek f57ca9c1af mwl8k: prepare for posting per-vif firmware commands
One of the bytes in the mwl8k firmware command header is the 'macid'
byte, which for per-vif commands indicates which of the BSSes this
command is intended for.  (For commands that are not per-vif commands,
this byte can just be 0.)

This patch adds mwl8k_post_pervif_cmd(), which will take the macid
assigned to this interface (to be done in ->add_interface()), copy it
into the command packet macid field, and post the command as usual.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:20 -05:00
Lennert Buytenhek f5bb87cfba mwl8k: convert the priv->vif pointer to a list of vifs
To prepare for adding multi-BSS support.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:19 -05:00
Lennert Buytenhek 06953235f4 mwl8k: use firmware capability field to decide which bands to register
Make the decision about whether to register the 2.4 and 5 GHz bands
with mac80211 by looking at the capability field in GET_HW_SPEC (STA
firmware only for now).  This enables 5 GHz STA operation.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:18 -05:00
Lennert Buytenhek 42574ea227 mwl8k: allow selecting 5 GHz channels
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:17 -05:00
Lennert Buytenhek 8707d02625 mwl8k: handle 5 GHz legacy rate bitmaps in firmware commands
Whenever mac80211 gives us a legacy rate bitmap in the context of the
5 GHz band, we need to remember to shift the bitmap left by 5 positions
before giving it to the firmware, as the firmware follows the bitmap
bit assignment of the 2.4 GHz rate table even if we're on the 5 GHz
band, and the 2.4 GHz rate table includes five non-OFDM rates at the
start that are not valid in the 5 GHz band.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:16 -05:00
Lennert Buytenhek 854783444b mwl8k: properly set receive status rate index on 5 GHz receive
The mwl8k firmware uses indices into the 2.4 GHz band rate table for
the receive descriptor channel field even if the packet was received
on a 5 GHz channel, while mac80211 expects an index into the 5 GHz
band rate table when packets are received on the 5 GHz band, which
presents a mismatch as the 5 GHz band rate table lacks the five
non-OFDM rates that the 2.4 GHz rate table starts with.

To handle this properly, we need to substract 5 from the rate index
field if the packet was received on a 5 GHz channel (and was not
received at an MCS rate).

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:15 -05:00
Lennert Buytenhek 4eae9edd38 mwl8k: add 5 GHz band channels and rates
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:14 -05:00
Lennert Buytenhek 1349ad2f06 mwl8k: move responsibility for initialising wiphy bands to GET_HW_SPEC
So that we can make 2.4 GHz and 5 GHz band registration conditional
on the capability bitmask returned by the firmware.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:13 -05:00
Lennert Buytenhek 777ad375d5 mwl8k: rename 2.4 GHz band/channels/rates related variables from FOO to FOO_24
To prepare for adding 5 GHz band/channels/rates.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:12 -05:00
Lennert Buytenhek ca66527c60 mwl8k: add another 88w8366 PCI ID
0x2a43 is a single-band (2.4GHz only) 88w8366 mini-PCIe card.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:11 -05:00
Lennert Buytenhek 657232b625 mwl8k: simplify sequence number assignment
By storing the sequence counter in << 4 format, like other drivers do.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:10 -05:00
Lennert Buytenhek c97470dd25 mwl8k: don't call SET_AID if we're not associated
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:09 -05:00
Lennert Buytenhek 9189c10087 mwl8k: remove (mostly) write-only variable priv->current_channel
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:08 -05:00
Lennert Buytenhek c92d4edecf mwl8k: update MODULE_FIRMWARE tags
Add MODULE_FIRMWARE tags for the mwl8k firmware images that don't
have them yet, and move them to where the firmware image names are
declared.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:21:07 -05:00
Lennert Buytenhek 67e2eb2795 mwl8k: move receive processing to tasklet
Like how TX reclaim is done in a tasklet, move receive processing
to tasklet context as well.  This can have nice benefits for CPU
utilisation and throughput, especially at 3-stream rates.

(Use the same CLEAR_SEL trick as the TX reclaim tasklet does, to
avoid having to touch the interrupt mask registers.)

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:10 -05:00
Lennert Buytenhek 1e9f9de3b1 mwl8k: keep TX_DONE interrupt masked while transmit reclaim is running
By making use of the CLEAR_SEL feature of the mwl8k host interface
interrupt controller, we can keep the TX_DONE interrupt source masked
while the transmit reclaim tasklet is running (NAPI style) without
having to touch the interrupt controller's interrupt mask register
when entering or exiting polling mode, and without having to do any
more register reads/writes than we do now.

When CLEAR_SEL is enabled on the TX_DONE interrupt source, reading
the interrupt status register will clear the TX_DONE status bit if
it was set, allowing it to be set again if a new TX_DONE event arrives
while we are running the TX reclaim tasklet, but such a new event will
then not trigger another PCI interrupt until a zero is written to the
TX_DONE interrupt status register bit.

I.e., if we write a zero to the TX_DONE interrupt source bit in the
interrupt status register when the TX reclaim tasklet thinks it's
done, a PCI interrupt will be triggered if a new TX_DONE event arrived
from the hardware between us deciding that there is no more work to do
and re-enabling the TX_DONE interrupt source, thereby avoiding the
classic NAPI poll mode exit race that would otherwise occur.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:10 -05:00
Lennert Buytenhek efb7c49a68 mwl8k: allow limiting the amount of transmit reclaim done
Add a limit argument to mwl8k_txq_reclaim(), to allow limiting the
number of packets that it will reclaim, and make it return the number
of packets that it reclaimed.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:10 -05:00
Lennert Buytenhek b64fe619e3 mwl8k: basic AP interface support
Add support for creating AP interfaces, and enabling beaconing.
This allows running a basic AP (11b/g mode only for now).

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:10 -05:00
Lennert Buytenhek a9e00b151e mwl8k: correctly set the mac_type field for AP SET_MAC_ADDR
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:09 -05:00
Lennert Buytenhek 3f5610ff56 mwl8k: implement AP firmware station database maintenance
STA firmware uses UPDATE_STADB to manipulate the hardware station
database, whereas AP firmware uses SET_NEW_STN -- this implements the
latter, and hooks it into mwl8k_sta_notify(), to be used if we're
running on AP firmware.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:09 -05:00
Lennert Buytenhek 088aab8b62 mwl8k: add the AP version of USE_FIXED_RATE
As with the STA version, unicast will use auto rate adaptation, but
the AP version allows setting the rates to be used for management and
multicast transmissions, which can be set based on the BSS basic rate
set.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:09 -05:00
Lennert Buytenhek b71ed2c6ce mwl8k: simplify mwl8k_cmd_use_fixed_rate()
As we always use the auto rate adaptation feature and never pass in
a rate table, USE_FIXED_RATE can be simplified somewhat.  While we're
at it, rename it to *_sta, as this is the STA version of the command.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:09 -05:00
Lennert Buytenhek 62abd3cfb2 mwl8k: bump the transmit wait timeout to 5 seconds
While it is reasonable to expect that at least one transmit ring entry
will be processed per second while we are waiting for the transmit
rings to drain, the firmware can end up doing batching of transmit ring
status writeback, which means that the transmit rings can appear stuck
for more than a second at a time.

Bump the TX drain wait timeout up from 1 to 5 seconds to account for
this.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:08 -05:00
Lennert Buytenhek b569e924a9 mwl8k: undo transmit queue 0/1 swapping in mwl8k_cmd_set_edca_params()
The comment and code in mwl8k_cmd_set_edca_params() suggest that the
mapping between SET_EDCA_PARAMS queue numbers and transmit rings isn't
actually 1:1, while tests show that the mapping is in fact 1:1.  So,
get rid of the transmit queue 0/1 swapping.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:08 -05:00
Lennert Buytenhek c2c2b12a8b mwl8k: minor cleanups
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-12 14:02:08 -05:00
John W. Linville 4f9b2a7dea Merge git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
Conflicts:
	net/mac80211/iface.c
2010-01-05 17:18:59 -05:00
Lennert Buytenhek 341c97918a mwl8k: pass GET_HW_SPEC capability bitmask up the stack
This enables HT association and AMPDU in the receive direction for
STA firmware images on hardware that supports it.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-01-05 17:13:35 -05:00