Commit graph

25330 commits

Author SHA1 Message Date
Luis Carlos 82fde74b94 [PATCH] libertas: convert libertas_mpp into anycast_mask
With firmware 5.220.11.p5, this allows to specify the anycast addresses the
device will listen to.

The anycast address range is C0:27:C0:27:C0:XX where XX goes from 00 to 1F (or
0 to 31 in dec). The value to write on anycast_mask will specify which
addresses the device listens to. Bits in a 32 bit int are numbered from 0
(least significative bit) to 31. A specific address ending in YY will be
listened to if bit YY in the value is set to one.

Examples:

0x00000000 : do not listen to any anycast address
0xFFFFFFFF : listen to every anycast address from :00 to :1F
0x00000013 : listen to anycast addresses :00, :01 and :04

Signed-off-by: Luis Carlos Cobo <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-12 14:07:54 -04:00
Dan Williams 2fb3bd6a23 [PATCH] libertas: actually send mesh frames to mesh netdev
Found by Luis; got broken during module split.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-12 14:02:41 -04:00
Luis Carlos Cobo Rus fff47f108d [PATCH] libertas: deauthenticate from AP in channel switch
This avoids channel mismatch between driver and firmware in case we change
channel while associated to an AP.

Signed-off-by: Luis Carlos Cobo Rus <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-12 14:02:32 -04:00
Luis Carlos Cobo Rus b8bedefd8f [PATCH] libertas: pull current channel from firmware on mesh autostart
Signed-off-by: Luis Carlos Cobo Rus <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-12 14:02:23 -04:00
Dan Williams 717c933920 [PATCH] libertas: reduce SSID and BSSID mixed-case abuse
Kill mixed case function names from scan.c/scan.h.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:46 -04:00
Dan Williams 8cf1dc098f [PATCH] libertas: remove WPA_SUPPLICANT structure
Unused.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:46 -04:00
Dan Williams d8efea2548 [PATCH] libertas: remove structure WLAN_802_11_SSID and libertas_escape_essid
Replace WLAN_802_11_SSID with direct 'ssid' and 'ssid_len' members
like ieee80211.  In the process, remove private libertas_escape_essid
and depend on the ieee80211 implementation of escape_essid instead.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:46 -04:00
Dan Williams 785e8f2679 [PATCH] libertas: tweak association debug output
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:46 -04:00
David Woodhouse 707985b385 [PATCH] libertas: fix big-endian associate command.
Byte-swapping length fields and then passing them to memcpy() considered
harmful.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:46 -04:00
David Woodhouse e5b3d472ad [PATCH] libertas: don't byte-swap firmware version number. It's a byte array.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:45 -04:00
David Woodhouse 86760088a7 [PATCH] libertas: more endianness fixes, in tx.c this time
Now we finally get connectivity. For a while, before something else dies...

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:45 -04:00
David Woodhouse bb793e2bfc [PATCH] libertas: More endianness fixes.
Now it at least manages to load the firmware.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:45 -04:00
David Woodhouse 981f187b7c [PATCH] libertas: first pass at fixing up endianness issues
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:45 -04:00
Dan Williams 123e0e0440 [PATCH] libertas: sparse fixes
Fix various issues reported by sparse.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:45 -04:00
David Woodhouse 0e8a5bd950 [PATCH] libertas: fix character set in README
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:45 -04:00
Luis Carlos Cobo Rus 7d8d28b31d [PATCH] libertas: support for mesh autostart on firmware 5.220.11
Signed-off-by: Luis Carlos Cobo Rus <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:45 -04:00
Luis Carlos Cobo Rus f5e05b697d [PATCH] libertas: split wext for eth and msh
Separate wireless handlers of mshX and ethX. ethX remains as before.

For mshX, it has been disabled set/get essid, wap and set mode. Get mode always
returns "Repeater" and by now we use the Nickname to show if the mesh is active
("Mesh") or not (empty). The rest remains as before.

Signed-off-by: Luis Carlos Cobo Rus <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:44 -04:00
Luis Carlos Cobo Rus 0a0d08aca5 [PATCH] libertas: make mac address configuration work with mesh interface too
Signed-off-by: Luis Carlos Cobo Rus <luiscarlos@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:44 -04:00
Luis Carlos Cobo Rus a23c58a3ac [PATCH] libertas: updated readme file
Fix some wording and blinding table command options, clarify argument list for
fwt_add and fwt_list, simplify fwt_list_route

Signed-off-by: Luis Carlos Cobo Rus <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:44 -04:00
Dan Williams 90a42210f2 [PATCH] libertas: Make WPA work through supplicant handshake
Fix WPA so it works up through the supplicant 4-Way handshake process.
Doesn't successfully pass traffic yet; may be problems installing
the GTK to the firmware.

- RSN needs to be enabled before the association command is sent
- Use keys from the association request not the adapter structure
- cmd_act_mac_strict_protection_enable != IW_AUTH_DROP_UNENCRYPTED
- Fix network filtering logic in is_network_compatible() WPA helpers

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:44 -04:00
Dan Williams 45f43de829 [PATCH] libertas: add more verbose debugging to libertas_cmd_80211_authenticate
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:44 -04:00
Dan Williams 57361c6edc [PATCH] libertas: debug print spacing fixes in assoc.c
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:44 -04:00
Dan Williams d9ad2f5df8 [PATCH] libertas: send SIOCGIWSCAN event after partial scans too
Any time the driver gets new scan results, even from partial scans,
it should send the scan event to userspace.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:44 -04:00
Dan Williams aeea0ab45a [PATCH] libertas: honor specific channel requests during association
Previously if a fixed channel was specified along with an SSID,
the channel request would be ignored during the association
process.  Instead, when searching for an adhoc or infrastructure
network to join, allow filtering results based on channel so
that the driver doesn't pick a BSS on a different channel than
requested.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:43 -04:00
Dan Williams ac26f81cce [PATCH] libertas: fix default adhoc channel
Inadvertently removed on a previous commit; causes the first
adhoc start to fail if a channel has not been set or no
other association has been made.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:43 -04:00
Dan Williams 80e78ef74d [PATCH] libertas: fix deadlock SIOCGIWSCAN handler
Update signal quality before the locked scan result translation loop,
because calling libertas_prepare_and_send_command() with the
'waitforrsp' option grabs adapter->lock in the command return processing,
leading to the deadlock.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:43 -04:00
Dan Williams 94b23855c0 [PATCH] libertas: correct error report paths for wlan_fwt_list_ioctl
Ensure the leave debug print gets triggered when necessary.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:43 -04:00
Dan Williams 6cfb008238 [PATCH] libertas: correctly balance locking in libertas_process_rx_command
adapter->lock should released after unlocking adapter->driver_lock to
balance the order in which they were locked at the top of the function.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:43 -04:00
Dan Williams 24d443b5d5 [PATCH] libertas: fix debug enter/leave prints for libertas_execute_next_command
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:42 -04:00
Dan Williams 3cf20931fa [PATCH] libertas: use compare_ether_addr() rather than memcmp() where appropriate
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:42 -04:00
Dan Williams 02eb229bbd [PATCH] libertas: use MAC_FMT and MAC_ARG where appropriate
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:42 -04:00
Dan Williams e76850d620 [PATCH] libertas: make association paths consistent
The BSS to associate with (in either Infrastructure or IBSS join
operations) is now stored in _one_ place in the association request (the
bss member), not two places as before (pattemptedbss and
curbssparams->bssdescriptor).

Association requests are passed to the necessary association functions
to (a) give them access to the bss member and (b) ensure that
association/join/start setup uses settings from the request, not the
current adapter settings (which may not be valid for the requested
settings).

Because the 'bss' member of the association request is used now, the
command return functions from associate and adhoc join/start need access
to the in-progress association request to update curbssparams when
everything is done.  The association worker moves the request from
pending to in-progress for the duration of the association attempt.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:42 -04:00
Dan Williams ef9a264b7a [PATCH] libertas: move channel changing into association framework
Handle channel changes through the deferred association framework
rather than directly.  Fixes errors when setting channels along
with other parameters like mode and SSID.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:42 -04:00
Marcelo Tosatti d43fb8ee3d [PATCH] libertas: fix oops on rmmod
Use list_for_each_entry_safe, to protect against list_del().

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:42 -04:00
Luis Carlos Cobo Rus 0e37275e9a [PATCH] libertas: cleanup of fwt_list_route processing
Signed-off-by: Luis Carlos Cobo Rus <luisca@cozybit.com>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:42 -04:00
Dan Williams eb8f7330e7 [PATCH] libertas: fix 'keep previous scan' behavior
Do not clear the scan list except under specific conditions, such as
when (a) user-requested, or (b) joining/starting an adhoc network.
Furthermore, only clear entries which match the SSID or BSSID of the
request, not the whole scan list.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:41 -04:00
Dan Williams fcdb53dbc7 [PATCH] libertas: make scan result handling more flexible
- use a linked list for scan results
- age scan results
- pass bss_descriptors around instead of indexes into the scan table
- lock access to the scan results
- stop returning EAGAIN from SIOCGIWSCAN handler

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:41 -04:00
Luis Carlos Cobo 90e8eafc93 [PATCH] libertas: updated mesh commands for 5.220.9.p11
Updated commands fwt_add and fwt_list, bt_list.
New commands: bt_get_invert, bt_set_invert, to invert the blinding table,
i.e., receive only frames from nodes listed in the BT.

This patch needs/is needed for firmware 5.220.9.p11.

Signed-off-by: Luis Carlos Cobo <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:41 -04:00
Luis Carlos Cobo Rus 7db283c914 [PATCH] libertas: version bump (321p0) and cmds update for new fw (5.220.10.p0)
This patch along with the previous commands update one, is necessary for
mesh and fwt ioctls to work properly with firmware version 5.220.10.p0
and later.

Signed-off-by: Luis Carlos Cobo Rus <luiscarlos@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:41 -04:00
Dan Williams 1db733eff6 [PATCH] libertas: don't tear down netdev in libertas_activate_card
libertas_activate_card() doesn't create the netdev, and shouldn't
free it on error.  The caller of libertas_activate_card() is
responsible for cleaning up errors from libertas_add_card(),
not libertas_activate_card().

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:41 -04:00
Dan Williams c72368310d [PATCH] libertas: correctly unregister mesh netdev on error
Subject says it all.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:41 -04:00
Dan Williams 4ace113876 [PATCH] libertas: replace 'macaddress' with 'bssid'
Start to normalize bss_descriptor with ieee80211_network so we can
eventually replace bss_descriptor more easily.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:40 -04:00
Dan Williams 7732ca45c6 [PATCH] libertas: call SET_NETDEV_DEV from common code
Move usage of SET_NETDEV_DEV into common code since it has nothing
to do with bus-specific devices.  Also fixes a bug where the mesh
device was getting SET_NETDEV_DEV called after register_netdevice,
resulting in no 'device' link in /sys/class/net/mshX/.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:40 -04:00
Luis Carlos Cobo 0681f98935 [PATCH] libertas: fixed kernel oops on module/card removal
Fixed kernel oops on module/card removal (using dongles)

Signed-off-by: Luis Carlos Cobo <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:40 -04:00
Luis Carlos Cobo b46794dffa [PATCH] libertas: add URB debug info
Signed-off-by: Luis Carlos Cobo <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:40 -04:00
Luis Carlos Cobo 60045136ab [PATCH] libertas: fixed incorrect assigment of fcs errors to frag errors
Signed-off-by: Luis Carlos Cobo <luisca@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:40 -04:00
Holger Schurig 634b8f49c1 [PATCH] libertas: remove unused variables in wlan_dev_t
Actually, this patch removev wlan_dev_t totally and puts the used variables
of it directly into wlan_private. That reduces one level of indirection and
looks a little bit simpler. It's now "priv->card" and not
"priv->wlan_dev.card" and "priv->dev" instead of "priv->wlan_dev.netdev"

Changed two occurences of "((wlan_private *) dev->priv)->wlan_dev.netdev"
into "dev", because I didn't see the point in doing pointer-ping-pong.

The variables "ioport", "upld_rcv" and "upld_type" where unused. They have
been removed.

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:40 -04:00
Holger Schurig ec3eef28d9 [PATCH] libertas: let DRV_NAME be overridable
For now, it's "libertas" by default, but that is overwritten in
if_usb.c/if_bootcmd.c and in if_cs.c.

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:40 -04:00
Holger Schurig 435a1acba2 [PATCH] libertas: fix RESET logic at unload time
Previously, we had a fixed array of 5 elements where we remembered all
initialized devices. This has been changed to use a "struct list_head"
organization, which is IMHO cleaner.

Also renamed usb_cardp to cardp, as in the reset of the code.

Renamed reset_device() to if_usb_reset_device() like many other functions.

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:39 -04:00
Holger Schurig 084708b610 [PATCH] libertas: split module into two (libertas.ko and usb8xxx.ko)
* add CONFIG_LIBERTAS to Kconfig
* remove global variable libertas_fw_name, the USB module might want to
    use a different default FW name than the CF module, so libertas_fw_name
    is now local to if_usb.c
* exported some symbols as GPL

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2007-06-11 14:28:39 -04:00