Commit Graph

39 Commits (1c9fbafc8c629c89183d6dccec67a8415513b0d1)

Author SHA1 Message Date
Roel Kluin 1f9e9ce1f9 Staging: wlan-ng: skb_p80211_to_ether() - payload_length is unsigned, check before subtraction
payload_length is unsigned, check before subtraction

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
2009-01-06 13:52:01 -08:00
Greg Kroah-Hartman a1da9da991 Staging: wlan-ng: fix compiler warnings
This fixes some compiler warnings in teh wlan-ng driver.

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:52:01 -08:00
Julia Lawall 9ba8aa7a94 Staging: wlan-ng: p80211wext.c: use ARRAY_SIZE
ARRAY_SIZE is more concise to use when the size of an array is divided by
the size of its type or the size of its first element.

The semantic patch that makes this change is as follows:
(http://www.emn.fr/x-info/coccinelle/)

// <smpl>
@i@
@@

#include <linux/kernel.h>

@depends on i using "paren.iso"@
type T;
T[] E;
@@

- (sizeof(E)/sizeof(E[...]))
+ ARRAY_SIZE(E)

@depends on i using "paren.iso"@
type T;
T[] E;
@@

- (sizeof(E)/sizeof(T))
+ ARRAY_SIZE(E)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:52:01 -08:00
Huang Weiyi d11e5f22ac Staging: wlan-ng: remove unused #include <version.h>
The file(s) below do not use LINUX_VERSION_CODE nor KERNEL_VERSION.
  drivers/staging/wlan-ng/p80211conv.c
  drivers/staging/wlan-ng/p80211req.c
  drivers/staging/wlan-ng/p80211wext.c
  drivers/staging/wlan-ng/prism2mgmt.c

This patch removes the said #include <version.h>.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:52:01 -08:00
Richard Kennedy 33ce0ca6e2 Staging: wlan-ng: p80211conv.c copy code from wlan-ng-devel branch to not drop packets
allow card to correctly receive network packets,
without this change all incoming packets are dropped.
code copied from the latest wlan-ng-devel tree.

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:52:00 -08:00
Richard Kennedy 8636cdedc5 Staging: wlan-ng: hfa384x_usbin_callback: check for hardware removed
hfa384x_usbin_callback: check for hardware removed

copied from latest wlan-ng-devel version

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:52:00 -08:00
Richard Kennedy 87b3df81fc Staging: wlan-ng: p80211wext don't set default key id twice
p80211wext don't set default key id twice

another change from wlan-ng-devel

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:52:00 -08:00
Richard Kennedy 46fa61f360 Staging: wlan-ng: p80211wext.c add latest changes & remove extra nulls from wext_handlers
add the latest changes from wlan-ng-devel
remove 2 stray nulls from the wext_handler table introduced
by the tidy up patch.

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:52:00 -08:00
Richard Kennedy 7b7e7e84bd Staging: wlan-ng: hfa384x_usb.c use newest version of 384x_drvr_start
include the needed fixes from Karl Relton
<karllinuxtest.relton@ntlworld.com>

see thread on linux-wlan-devel mailing list
"Possible cause of those pesky hfa384x_usbctlx_complete_sync errors"

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Cc: Karl Relton <karllinuxtest.relton@ntlworld.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:59 -08:00
Richard Kennedy 1d1b69851b Staging: wlan-ng: prism2_usb.c always enable the card in probe_usb
always enable card in probe_usb
& update register_wlandev to match latest wlan-ng-dev tree.

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:58 -08:00
Richard Kennedy ee313528d9 Staging: wlan-ng: p80211netdev.c fix netdev alloc to prevent oops on device start
a version of this patch is in the wlan-ng_devel tree

initializes netdev correctly to prevent an oops on device start.

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:58 -08:00
Solomon Peachy 56afef56eb Staging: wlan-ng: Purge all MIBs not used internally.
The next step is to bypass the MIB calling mechanism altogether and just
invoke the hardware directly where needed, but at least now the list has
been paired down considerably.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:58 -08:00
Solomon Peachy e02c69b8af Staging: wlan-ng: Consolidate wlan-ng into a single module.
There's no point in having a separate 'p80211' module, as nobody else is
ever going to use it.  Push everyting into a single module, and get rid
of all exports.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:57 -08:00
Solomon Peachy 1e7201836c Staging: wlan-ng: Delete a pile of unused mibs. And fix WEXT SET_TXPOWER.
Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:57 -08:00
Solomon Peachy cbec30c4c0 Staging: wlan-ng: Delete a large pile of now-unused code.
Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:57 -08:00
Solomon Peachy aec6a5f034 Staging: wlan-ng: use WIRELESS_EXT, not CONFIG_WIRELESS_EXT
Kconfig doesn't work with variables starting with CONFIG_

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:56 -08:00
Solomon Peachy fc4a76ff19 Staging: wlan-ng: Wireless Extension support is mandatory.
So take away the option to disable it.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:56 -08:00
Solomon Peachy 575a8a5c28 Staging: wlan-ng: Eliminate all backwards-compatible kernel code.
It's not needed at all anymore now that we are in the kernel tree.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:56 -08:00
Solomon Peachy aaad430378 Staging: wlan-ng: Use standard kernel integer (u32/s32/etc) types.
wlan-ng needed to interact with userspace, and support very old kernels,
so it used to define its own types for integers to ensure consistency.

It's all rather irrelevant now.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:56 -08:00
Solomon Peachy 5704976fa9 Staging: wlan-ng: Eliminate usage of procfs.
These files are not needed to work properly, and don't belong in procfs

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:55 -08:00
Solomon Peachy ff1ae8f3c1 Staging: wlan-ng: Eliminate local 'version.h'
The kernel provides us with the proper version of this file.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:55 -08:00
Solomon Peachy 905862c9f9 Staging: wlan-ng: Eliminate one more rx mtu test.
It also isn't needed.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:55 -08:00
Solomon Peachy 9d86349e9c Staging: wlan-ng: Get rid of the MTU tests in the rx conversion path.
They are not needed.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:55 -08:00
Solomon Peachy 5db8dcc98b Staging: wlan-ng: Remove AP-only code from MLME functions.
It is not needed in this driver.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:54 -08:00
Solomon Peachy f980c178ea Staging: wlan-ng: Eliminate a boatload of tertiaryAP-only code.
Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:54 -08:00
Solomon Peachy 8a1396ef7e Staging: wlan-ng: Eliminate all backwards-compatibility for <2.6.13 kernels.
Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:54 -08:00
Solomon Peachy 68a193e4bb Staging: wlan-ng: Eliminate more <2.6 kernel support.
Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:54 -08:00
Solomon Peachy 187a769636 Staging: wlan-ng: Make wlan-ng use WEXT mode by default.
As this is the kernel default mode.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:53 -08:00
Solomon Peachy dff1dc8caa Staging: wlan-ng: Delete PCI/PLX/PCMCIA-specific code.
Also delete a large pile of code that existed to support <2.6 kernels.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:53 -08:00
Solomon Peachy fe5755f61a Staging: wlan-ng: Update Help text to mention prism3 devices.
The driver also supports prism3 devices

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:53 -08:00
Solomon Peachy c9b01df34b Staging: wlan-ng: Remove PCI/PLX/PCMCIA files.
This portion of the driver is not needed at all, so remove it.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:53 -08:00
Harvey Harrison a337957247 staging: correct dubious use of !x & y
Noticed by sparse:
drivers/staging/me4000/me4000.c:1213:43: warning: dubious: !x & y
drivers/staging/wlan-ng/p80211wext.c:1583:21: warning: dubious: !x & y

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06 13:51:38 -08:00
Wang Chen 979123d534 staging-p80211: Kill directly reference of netdev->priv
In this driver, netdev's private data is wlandevice_t.  And the
wlandev(type of wlandevice_t) is exist before netdev be allocated.  So
use netdev->ml_priv to point to the private data.

I am not sure whether I should consider the kernel version older than
2.3.38.  Because in those kernels, netdevice_t is "structure dev"
instead of "structure net_device" and of course "dev->ml_priv" will
cause compile error.  But before my patch, in function wlan_setup(),
there is a ether_setup(net_device) which already broke kernels which
older than 2.3.38.

Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
2008-12-06 23:58:37 -08:00
Harvey Harrison 2ae5a6d20e Staging: remove remaining uses of __FUNCTION__
__FUNCTION__ is gcc-specific, use __func__

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-10-22 09:56:36 -07:00
Greg Kroah-Hartman 0c74433e31 Staging: wlan-ng: fix build error if wireless networking is not enabled
Thanks to Ingo for pointing this out.

Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-10-22 09:56:35 -07:00
Huang Weiyi ec7c35b852 staging: wlan-ng: prism2: remove more duplicated #include
Removed duplicated #include "version.h" in
drivers/staging/wlan-ng/p80211wep.c.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-10-22 09:56:31 -07:00
Huang Weiyi 5667f35aea Staging: wlan-ng: prism2: remove duplicated #include
Removed duplicated #include "wlan_compat.h" in
drivers/staging/wlan-ng/prism2mib.c.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-10-22 09:56:31 -07:00
Mariusz Kozlowski b4c0ed1169 staging: balance parenthesis in wlan-ng headers
Balance parenthesis in HFA384x_CMD_QOS_GET macro.

Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-10-22 09:56:30 -07:00
Greg Kroah-Hartman 00b3ed1685 Staging: add wlan-ng prism2 usb driver
This adds the wlan-ng prism2 USB driver to the drivers/staging tree.

The code was originally written by the linux-wlan-ng team, patched by
some Novell engineers to properly work on newer kernels, and then hacked
into place in order to get it to build properly in a single subdirectory
within the kernel tree by me.

It supports a wide range of older USB prism2 devices, and contains a
80211 stack to support this single driver.

Cc: Christian Zoz <zoz@suse.de>
Cc: Andreas Gruenbacher <agruen@suse.de>
Cc: linux-wireless <linux-wireless@vger.kernel.org>
Cc: John Linville <linville@tuxdriver.com>
Cc: Helmut Schaa <helmut.schaa@googlemail.com>
Cc: linux-wlan-ng <solomon@linux-wlan.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-10-10 15:31:10 -07:00