- 16 Jul, 2013 10 commits
-
-
Simon Wunderlich authored
This was originally designed to fail when a 40+/40- mode can not be used, but basic modes (such as 5/10/20 MHz) must be handled with an error. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
Use a chandef instead of just the channel for scanning, and enable 5/10 Mhz scanning for IBSS mode. Also reporting is changed to the new inform_bss functions. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
Some regulations (like germany, but also FCC) express their transmission power limit in dBm/MHz or mW/MHz. To cope with that and be on the safe side, reduce the maximum power to half (10 MHz) or quarter (5 MHz) when operating on these reduced bandwidth channels. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
Mandatory rates for 5 and 10 MHz are different from the rates used for 20 MHz in 2.4 GHz mode, as they use OFDM only. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
The various components accessing the bitrates table must use consider the used channel bandwidth to select only available rates or calculate the bitrate correctly. There are some rates in reduced bandwidth modes which can't be represented as multiples of 500kbps, like 2.25 MBit/s in 5 MHz mode. The standard suggests to round up to the next multiple of 500kbps, just do that in mac80211 as well. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> [make rate unsigned in ieee80211_add_tx_radiotap_header(), squash fix] Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
Wireshark already defines radiotap channel flags for 5 and 10 MHz, so just use them in Linux radiotap too. Furthermore, add rx status flags to allow drivers to report when they received data on 5 or 10 MHz channels. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
according to IEEE 802.11-2012 section 18, various timings change when using 5 MHz and 10 MHz. Reflect this by using a "shift" when calculating durations. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
5 and 10 MHz support needs to know the current operating channel width, add the chandef to the rate control API. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Johannes Berg authored
When per-chain signal information is available, don't add the antenna field once but instead add a radiotap namespace for each chain containing the chain/antenna number and the signal strength on that chain. Signed-off-by:
Johannes Berg <johannes.berg@intel.com> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
Simon Wunderlich authored
Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes@sipsolutions.net>
-
- 03 Jul, 2013 1 commit
-
-
Kees Cook authored
For the workqueue creation interfaces that do not expect format strings, make sure they cannot accidently be parsed that way. Additionally, clean up calls made with a single parameter that would be handled as a format string. Many callers are passing potentially dynamic string content, so use "%s" in those cases to avoid any potential accidents. Signed-off-by:
Kees Cook <keescook@chromium.org> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- 24 Jun, 2013 2 commits
-
-
Thomas Pedersen authored
Previously the default mesh STA nonpeer power mode was UNKNOWN (0) make the default mesh STA power mode ACTIVE, to prevent unnecessary frame buffering while peering is not yet complete. Fixes a panic in ath9k_htc when adding stations from userspace, and mcast buffered frames are later released. Thanks to Bob Copeland for his help debugging this. Signed-off-by:
Thomas Pedersen <thomas@cozybit.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Thomas Pedersen authored
Useful for userspace mesh to authenticate and peer without a station entry, since both steps may fail anyway. Signed-off-by:
Thomas Pedersen <thomas@cozybit.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 19 Jun, 2013 1 commit
-
-
Johannes Berg authored
Doing so will allow us to hold the BSS (not just ref it) over the association process, thus ensuring that it doesn't time out and gets invisible to the user (e.g. in 'iw wlan0 link'.) This also fixes a leak in mac80211 where it doesn't always release the BSS struct properly in all cases where calling this function. This leak was reported by Ben Greear. Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 18 Jun, 2013 4 commits
-
-
Antonio Quartulli authored
This reverts commit 6d810f10 In this way an IBSS station will not use the AUTH messages to trigger a state reinitialisation anymore. The behaviour was racy and was not working properly. It has been introduced to help wpa_supplicant to support IBSS/RSN, however all the logic is now getting moved into wpa_s itself which will also be in charge of handling the AUTH messages thanks to the mgmt frame registration. If userspace does not register for receiving AUTH frames then mac80211 will still reply by itself. At the same time, the auth frame registration counter can be removed since it is not needed anymore. Signed-off-by:
Antonio Quartulli <antonio@open-mesh.com> [remove unused variable] Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Simon Wunderlich authored
This should make some parts cleaner and is also required for handling 5/10 MHz properly. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Simon Wunderlich authored
This is a collection of minor fixes: * don't allow HT IEs in IBSS for 5/10 MHz * don't allow HT IEs in Mesh for 5/10 MHz * don't downgrade from/to 5 and 10 MHz channels * don't try HT rates for 5 and 10 MHz channels when selecting rates Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Thomas Pedersen authored
Instead of updating the mesh beacon immediately when requested (which would require the sdata_lock()), defer it to the mac80211 workqueue. Fixes yet another deadlock on calling sta_info_flush() with the sdata_lock() held from ieee80211_stop_mesh(). We could just drop the sdata_lock() around the mesh_sta_cleanup() call, but this path is also taken from several non-locked error paths. Signed-off-by:
Thomas Pedersen <thomas@cozybit.com> [fix comment position] Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 13 Jun, 2013 3 commits
-
-
Ilan Peer authored
Signed-off-by:
Ilan Peer <ilan.peer@intel.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Alexander Bondar authored
Track the AP's beacon rate in the scan BSS data and in the interface configuration to let the drivers know which rate the AP is using. This information may be used by drivers, in our case to let the firmware optimise beacon RX. Signed-off-by:
Alexander Bondar <alexander.bondar@intel.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Ben Greear authored
All accesses of the tid_start_tx lock should be protected by sta->lock if there is any chance that another thread could still be accessing the sta object. Signed-off-by:
Ben Greear <greearb@candelatech.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 12 Jun, 2013 4 commits
-
-
Johannes Berg authored
Ben reports that kmemleak is saying TX aggregation TID structs are leaked. Given his workload, I suspect that they're leaked because stations are destroyed before their aggregation sessions get a chance to start. Fix this by simply freeing structs that are not used yet. Reported-by:
Ben Greear <greearb@candelatech.com> Tested-by:
Ben Greear <greearb@candelatech.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Simon Wunderlich authored
The order of parameters was mixed up, introduced in commit "mac80211: improve the rate control API" Cc: Felix Fietkau <nbd@openwrt.org> Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Mathias Kretschmer <mathias.kretschmer@fokus.fraunhofer.de> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Simon Wunderlich authored
When a CAC is running and stop_ap is called (e.g. when hostapd is killed while performing CAC), the CAC must be aborted immediately. Otherwise ieee80211_stop_ap() will try to stop it when it's too late - wdev->channel is already NULL and the abort event can not be generated. Signed-off-by:
Simon Wunderlich <siwu@hrz.tu-chemnitz.de> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
There are some APs, notably 2G/3G/4G Wifi routers, specifically the "Onda PN51T", "Vodafone PocketWiFi 2", "ZTE MF60" and a similar T-Mobile branded device [1] that erroneously don't include all the needed information in (re)association response frames. Work around this by assuming the information is the same as it was in the beacon or probe response and using the data from there instead. This fixes https://bugzilla.kernel.org/show_bug.cgi?id=58881. [1] https://bbs.archlinux.org/viewtopic.php?pid=1277305 Note that this requires marking the first ieee802_11_parse_elems() argument const, otherwise we'd get a compiler warning. Cc: stable@vger.kernel.org Reported-and-tested-by:
Michal Zajac <manwe@manwe.pl> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 11 Jun, 2013 4 commits
-
-
Antonio Quartulli authored
cfg80211 passes a NULL channel to mgmt_tx if the frame has to be sent on the one currently in use by the device. Make the implementation of mgmt_tx correctly handle this case. Fail if offchan is required. Signed-off-by:
Antonio Quartulli <antonio@open-mesh.com> [fix RCU locking] Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Ashok Nagarajan authored
Currently mesh uses mandatory rates as the default basic rates. Allow basic rates to be configured during mesh join. Basic rates are applied only if channel is also provided with mesh join command. Signed-off-by:
Ashok Nagarajan <ashok@cozybit.com> [some whitespace fixes, refuse basic rates w/o channel] Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Colleen Twitty authored
The time it takes to see the peer link expire may differ by a minute since sta_expire() is run once a minute as a mesh housekeeping task. Signed-off-by:
Colleen Twitty <colleen@cozybit.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Thomas Pedersen authored
The patch "cfg80211/mac80211: use cfg80211 wdev mutex in mac80211" introduced several deadlocks by converting the ifmsh->mtx to wdev->mtx. Solve these by: 1. drop the cancel_work_sync() in ieee80211_stop_mesh(). Instead make the mesh work conditional on whether the mesh is running or not. 2. lock the mesh work with sdata_lock() to protect beacon updates and prevent races with wdev->mesh_id_len or cfg80211. Signed-off-by:
Thomas Pedersen <thomas@cozybit.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 05 Jun, 2013 3 commits
-
-
Johannes Berg authored
Some kernel-doc fixes for forgotten fields and renamed things. Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Alexander Bondar authored
Currently beacon availability upon association is marked by have_beacon flag of assoc_data structure that becomes unavailable when association completes. However beacon availability indication is required also after association to inform a driver. Currently dtim_period parameter is used for this purpose. Move have_beacon flag to another structure, persistant throughout a interface's life cycle. Use suitable sematics for beacon availability indication. Signed-off-by:
Alexander Bondar <alexander.bondar@intel.com> [fix another instance of BSS_CHANGED_DTIM_PERIOD in docs] Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Alexander Bondar authored
ieee80211_rx_bss_info() deals with dtim_period setting and PS update when associated. Move all these to another locations cleaning this function. Also, the current implementation is buggy because when it calls ieee80211_recalc_ps() bss_conf->dtim_period is notset properly yet and thus nothing will happen. Signed-off-by:
Alexander Bondar <alexander.bondar@intel.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 04 Jun, 2013 3 commits
-
-
Johannes Berg authored
Do some cleanups in the cfg80211 SME APIs, which are only used by mac80211. Most of these functions get a frame passed, and there isn't really any reason to export multiple functions as cfg80211 can check the frame type instead, do that. Additionally, the API functions have confusing names like cfg80211_send_...() which was meant to indicate that it sends an event to userspace, but gets a bit confusing when there's both TX and RX and they're not all clearly labeled. Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Pontus Fuchs authored
The connection monitor needs to know the tx status of nullframes to work properly. Signed-off-by:
Pontus Fuchs <pontus.fuchs@gmail.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Felix Fietkau authored
Signed-off-by:
Felix Fietkau <nbd@openwrt.org> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 03 Jun, 2013 4 commits
-
-
Johannes Berg authored
There's no need to take up the space for devices that don't support WoWLAN, and most drivers can even make the support data static const (except where it's modified at runtime.) Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Jacob Minshall authored
Cap max peerings at 63 in accordance with IEEE-2012 8.4.2.100.7. Triggers a beacon regeneration every time the number of peerings changes. Previously this would only happen if the "accepting peerings" bit changed. Signed-off-by:
Jacob Minshall <jacob@cozybit.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Thomas Pedersen authored
nl80211 has already verified the mesh TTL on setting the mesh config, so no need to check it again in mac80211. Signed-off-by:
Thomas Pedersen <thomas@cozybit.com> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
My cfg80211/mac80211 locking unification broke the sdata locking in ieee80211_set_power_mgmt, it needs to acquire the lock for __ieee80211_request_smps(). Add the locking. Reported-by:
Jakub Kicinski <kubakici@wp.pl> Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-
- 29 May, 2013 1 commit
-
-
Johannes Berg authored
If the driver advertised support for a CAB queue, then we should put all multicast frames there, otherwise sending them can be racy with clients going to sleep while we TX a frame. To avoid this, always TX multicast frames on the multicast queue. It seems like even drivers not using the queue framework might want to do this which would mean also moving the IEEE80211_TX_CTL_SEND_AFTER_DTIM flag assignment, but it also seems that drivers behave differently here so that just moving it wouldn't be a good idea. It'd be better to modify those drivers to use the queue framework. Signed-off-by:
Johannes Berg <johannes.berg@intel.com>
-