···13531353S: Supported13541354F: drivers/net/wireless/ath/ath9k/1355135513561356+WILOCITY WIL6210 WIRELESS DRIVER13571357+M: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>13581358+L: linux-wireless@vger.kernel.org13591359+L: wil6210@qca.qualcomm.com13601360+S: Supported13611361+W: http://wireless.kernel.org/en/users/Drivers/wil621013621362+F: drivers/net/wireless/ath/wil6210/13631363+13561364CARL9170 LINUX COMMUNITY WIRELESS DRIVER13571365M: Christian Lamparter <chunkeey@googlemail.com>13581366L: linux-wireless@vger.kernel.org
+1-2
drivers/bcma/Kconfig
···67676868config BCMA_DRIVER_GPIO6969 bool "BCMA GPIO driver"7070- depends on BCMA7171- select GPIOLIB7070+ depends on BCMA && GPIOLIB7271 help7372 Driver to provide access to the GPIO pins of the bcma bus.7473
···217217 * @rx_oom_err: No. of frames dropped due to OOM issues.218218 * @rx_rate_err: No. of frames dropped due to rate errors.219219 * @rx_too_many_frags_err: Frames dropped due to too-many-frags received.220220- * @rx_drop_rxflush: No. of frames dropped due to RX-FLUSH.221220 * @rx_beacons: No. of beacons received.222221 * @rx_frags: No. of rx-fragements received.223222 */···235236 u32 rx_oom_err;236237 u32 rx_rate_err;237238 u32 rx_too_many_frags_err;238238- u32 rx_drop_rxflush;239239 u32 rx_beacons;240240 u32 rx_frags;241241};
···11+config WIL621022+ tristate "Wilocity 60g WiFi card wil6210 support"33+ depends on CFG8021144+ depends on PCI55+ default n66+ ---help---77+ This module adds support for wireless adapter based on88+ wil6210 chip by Wilocity. It supports operation on the99+ 60 GHz band, covered by the IEEE802.11ad standard.1010+1111+ http://wireless.kernel.org/en/users/Drivers/wil62101212+1313+ If you choose to build it as a module, it will be called1414+ wil62101515+1616+config WIL6210_ISR_COR1717+ bool "Use Clear-On-Read mode for ISR registers for wil6210"1818+ depends on WIL62101919+ default y2020+ ---help---2121+ ISR registers on wil6210 chip may operate in either2222+ COR (Clear-On-Read) or W1C (Write-1-to-Clear) mode.2323+ For production code, use COR (say y); is default since2424+ it saves extra target transaction;2525+ For ISR debug, use W1C (say n); is allows to monitor ISR2626+ registers with debugfs. If COR were used, ISR would2727+ self-clear when accessed for debug purposes, it makes2828+ such monitoring impossible.2929+ Say y unless you debug interrupts
···77#include <linux/hw_random.h>88#include <linux/bcma/bcma.h>99#include <linux/ssb/ssb.h>1010+#include <linux/completion.h>1011#include <net/mac80211.h>11121213#include "debugfs.h"···723722struct b43_request_fw_context {724723 /* The device we are requesting the fw for. */725724 struct b43_wldev *dev;725725+ /* a completion event structure needed if this call is asynchronous */726726+ struct completion fw_load_complete;727727+ /* a pointer to the firmware object */728728+ const struct firmware *blob;726729 /* The type of firmware to request. */727730 enum b43_firmware_file_type req_type;728731 /* Error messages for each firmware type. */
+41-13
drivers/net/wireless/b43/main.c
···20882088 b43warn(wl, text);20892089}2090209020912091+static void b43_fw_cb(const struct firmware *firmware, void *context)20922092+{20932093+ struct b43_request_fw_context *ctx = context;20942094+20952095+ ctx->blob = firmware;20962096+ complete(&ctx->fw_load_complete);20972097+}20982098+20912099int b43_do_request_fw(struct b43_request_fw_context *ctx,20922100 const char *name,20932093- struct b43_firmware_file *fw)21012101+ struct b43_firmware_file *fw, bool async)20942102{20952095- const struct firmware *blob;20962103 struct b43_fw_header *hdr;20972104 u32 size;20982105 int err;···21382131 B43_WARN_ON(1);21392132 return -ENOSYS;21402133 }21412141- err = request_firmware(&blob, ctx->fwname, ctx->dev->dev->dev);21342134+ if (async) {21352135+ /* do this part asynchronously */21362136+ init_completion(&ctx->fw_load_complete);21372137+ err = request_firmware_nowait(THIS_MODULE, 1, ctx->fwname,21382138+ ctx->dev->dev->dev, GFP_KERNEL,21392139+ ctx, b43_fw_cb);21402140+ if (err < 0) {21412141+ pr_err("Unable to load firmware\n");21422142+ return err;21432143+ }21442144+ /* stall here until fw ready */21452145+ wait_for_completion(&ctx->fw_load_complete);21462146+ if (ctx->blob)21472147+ goto fw_ready;21482148+ /* On some ARM systems, the async request will fail, but the next sync21492149+ * request works. For this reason, we dall through here21502150+ */21512151+ }21522152+ err = request_firmware(&ctx->blob, ctx->fwname,21532153+ ctx->dev->dev->dev);21422154 if (err == -ENOENT) {21432155 snprintf(ctx->errors[ctx->req_type],21442156 sizeof(ctx->errors[ctx->req_type]),21452145- "Firmware file \"%s\" not found\n", ctx->fwname);21572157+ "Firmware file \"%s\" not found\n",21582158+ ctx->fwname);21462159 return err;21472160 } else if (err) {21482161 snprintf(ctx->errors[ctx->req_type],···21712144 ctx->fwname, err);21722145 return err;21732146 }21742174- if (blob->size < sizeof(struct b43_fw_header))21472147+fw_ready:21482148+ if (ctx->blob->size < sizeof(struct b43_fw_header))21752149 goto err_format;21762176- hdr = (struct b43_fw_header *)(blob->data);21502150+ hdr = (struct b43_fw_header *)(ctx->blob->data);21772151 switch (hdr->type) {21782152 case B43_FW_TYPE_UCODE:21792153 case B43_FW_TYPE_PCM:21802154 size = be32_to_cpu(hdr->size);21812181- if (size != blob->size - sizeof(struct b43_fw_header))21552155+ if (size != ctx->blob->size - sizeof(struct b43_fw_header))21822156 goto err_format;21832157 /* fallthrough */21842158 case B43_FW_TYPE_IV:···21902162 goto err_format;21912163 }2192216421932193- fw->data = blob;21652165+ fw->data = ctx->blob;21942166 fw->filename = name;21952167 fw->type = ctx->req_type;21962168···22002172 snprintf(ctx->errors[ctx->req_type],22012173 sizeof(ctx->errors[ctx->req_type]),22022174 "Firmware file \"%s\" format error.\n", ctx->fwname);22032203- release_firmware(blob);21752175+ release_firmware(ctx->blob);2204217622052177 return -EPROTO;22062178}···22512223 goto err_no_ucode;22522224 }22532225 }22542254- err = b43_do_request_fw(ctx, filename, &fw->ucode);22262226+ err = b43_do_request_fw(ctx, filename, &fw->ucode, true);22552227 if (err)22562228 goto err_load;22572229···22632235 else22642236 goto err_no_pcm;22652237 fw->pcm_request_failed = false;22662266- err = b43_do_request_fw(ctx, filename, &fw->pcm);22382238+ err = b43_do_request_fw(ctx, filename, &fw->pcm, false);22672239 if (err == -ENOENT) {22682240 /* We did not find a PCM file? Not fatal, but22692241 * core rev <= 10 must do without hwcrypto then. */···23242296 default:23252297 goto err_no_initvals;23262298 }23272327- err = b43_do_request_fw(ctx, filename, &fw->initvals);22992299+ err = b43_do_request_fw(ctx, filename, &fw->initvals, false);23282300 if (err)23292301 goto err_load;23302302···23832355 default:23842356 goto err_no_initvals;23852357 }23862386- err = b43_do_request_fw(ctx, filename, &fw->initvals_band);23582358+ err = b43_do_request_fw(ctx, filename, &fw->initvals_band, false);23872359 if (err)23882360 goto err_load;23892361
···3028302830293029 len = wpa_ie->len + TLV_HDR_LEN;30303030 data = (u8 *)wpa_ie;30313031- offset = 0;30313031+ offset = TLV_HDR_LEN;30323032 if (!is_rsn_ie)30333033 offset += VS_IE_FIXED_HDR_LEN;30343034- offset += WPA_IE_VERSION_LEN;30343034+ else30353035+ offset += WPA_IE_VERSION_LEN;3035303630363037 /* check for multicast cipher suite */30373038 if (offset + WPA_IE_MIN_OUI_LEN > len) {
+1
drivers/net/wireless/brcm80211/brcmsmac/debug.h
···11/*22 * Copyright (c) 2012 Broadcom Corporation33+ * Copyright (c) 2012 Canonical Ltd.34 *45 * Permission to use, copy, modify, and/or distribute this software for any56 * purpose with or without fee is hereby granted, provided that the above
···3958395839593959 memset(&il->staging, 0, sizeof(il->staging));3960396039613961- if (!il->vif) {39613961+ switch (il->iw_mode) {39623962+ case NL80211_IFTYPE_UNSPECIFIED:39623963 il->staging.dev_type = RXON_DEV_TYPE_ESS;39633963- } else if (il->vif->type == NL80211_IFTYPE_STATION) {39643964+ break;39653965+ case NL80211_IFTYPE_STATION:39643966 il->staging.dev_type = RXON_DEV_TYPE_ESS;39653967 il->staging.filter_flags = RXON_FILTER_ACCEPT_GRP_MSK;39663966- } else if (il->vif->type == NL80211_IFTYPE_ADHOC) {39683968+ break;39693969+ case NL80211_IFTYPE_ADHOC:39673970 il->staging.dev_type = RXON_DEV_TYPE_IBSS;39683971 il->staging.flags = RXON_FLG_SHORT_PREAMBLE_MSK;39693972 il->staging.filter_flags =39703973 RXON_FILTER_BCON_AWARE_MSK | RXON_FILTER_ACCEPT_GRP_MSK;39713971- } else {39743974+ break;39753975+ default:39723976 IL_ERR("Unsupported interface type %d\n", il->vif->type);39733977 return;39743978 }···45544550EXPORT_SYMBOL(il_mac_add_interface);4555455145564552static void45574557-il_teardown_interface(struct il_priv *il, struct ieee80211_vif *vif,45584558- bool mode_change)45534553+il_teardown_interface(struct il_priv *il, struct ieee80211_vif *vif)45594554{45604555 lockdep_assert_held(&il->mutex);45614556···45634560 il_force_scan_end(il);45644561 }4565456245664566- if (!mode_change)45674567- il_set_mode(il);45684568-45634563+ il_set_mode(il);45694564}4570456545714566void···4576457545774576 WARN_ON(il->vif != vif);45784577 il->vif = NULL;45794579-45804580- il_teardown_interface(il, vif, false);45784578+ il->iw_mode = NL80211_IFTYPE_UNSPECIFIED;45794579+ il_teardown_interface(il, vif);45814580 memset(il->bssid, 0, ETH_ALEN);4582458145834582 D_MAC80211("leave\n");···46864685 }4687468646884687 /* success */46894689- il_teardown_interface(il, vif, true);46904688 vif->type = newtype;46914689 vif->p2p = false;46924692- err = il_set_mode(il);46934693- WARN_ON(err);46944694- /*46954695- * We've switched internally, but submitting to the46964696- * device may have failed for some reason. Mask this46974697- * error, because otherwise mac80211 will not switch46984698- * (and set the interface type back) and we'll be46994699- * out of sync with it.47004700- */46904690+ il->iw_mode = newtype;46914691+ il_teardown_interface(il, vif);47014692 err = 0;4702469347034694out:
+19-7
drivers/net/wireless/iwlwifi/dvm/tx.c
···10711071{10721072 u16 status = le16_to_cpu(tx_resp->status.status);1073107310741074+ info->flags &= ~IEEE80211_TX_CTL_AMPDU;10751075+10741076 info->status.rates[0].count = tx_resp->failure_frame + 1;10751077 info->flags |= iwl_tx_status_to_mac80211(status);10761078 iwlagn_hwrate_to_tx_control(priv, le32_to_cpu(tx_resp->rate_n_flags),···11451143 next_reclaimed = ssn;11461144 }1147114511481148- if (tid != IWL_TID_NON_QOS) {11491149- priv->tid_data[sta_id][tid].next_reclaimed =11501150- next_reclaimed;11511151- IWL_DEBUG_TX_REPLY(priv, "Next reclaimed packet:%d\n",11521152- next_reclaimed);11531153- }11541154-11551146 iwl_trans_reclaim(priv->trans, txq_id, ssn, &skbs);1156114711571148 iwlagn_check_ratid_empty(priv, sta_id, tid);···11951200 if (!is_agg)11961201 iwlagn_non_agg_tx_status(priv, ctx, hdr->addr1);1197120212031203+ /*12041204+ * W/A for FW bug - the seq_ctl isn't updated when the12051205+ * queues are flushed. Fetch it from the packet itself12061206+ */12071207+ if (!is_agg && status == TX_STATUS_FAIL_FIFO_FLUSHED) {12081208+ next_reclaimed = le16_to_cpu(hdr->seq_ctrl);12091209+ next_reclaimed =12101210+ SEQ_TO_SN(next_reclaimed + 0x10);12111211+ }12121212+11981213 is_offchannel_skb =11991214 (info->flags & IEEE80211_TX_CTL_TX_OFFCHAN);12001215 freed++;12161216+ }12171217+12181218+ if (tid != IWL_TID_NON_QOS) {12191219+ priv->tid_data[sta_id][tid].next_reclaimed =12201220+ next_reclaimed;12211221+ IWL_DEBUG_TX_REPLY(priv, "Next reclaimed packet:%d\n",12221222+ next_reclaimed);12011223 }1202122412031225 if (!is_agg && freed != 1)
+1
drivers/net/wireless/iwlwifi/pcie/rx.c
···11721172 else if (test_bit(STATUS_INT_ENABLED, &trans_pcie->status) &&11731173 !trans_pcie->inta)11741174 iwl_enable_interrupts(trans);11751175+ return IRQ_HANDLED;1175117611761177none:11771178 /* re-enable interrupts here since we don't have anything to service. */
+3-16
drivers/net/wireless/mwifiex/cfg80211.c
···14581458 struct cfg80211_ssid req_ssid;14591459 int ret, auth_type = 0;14601460 struct cfg80211_bss *bss = NULL;14611461- u8 is_scanning_required = 0, config_bands = 0;14611461+ u8 is_scanning_required = 0;1462146214631463 memset(&req_ssid, 0, sizeof(struct cfg80211_ssid));14641464···1476147614771477 /* disconnect before try to associate */14781478 mwifiex_deauthenticate(priv, NULL);14791479-14801480- if (channel) {14811481- if (mode == NL80211_IFTYPE_STATION) {14821482- if (channel->band == IEEE80211_BAND_2GHZ)14831483- config_bands = BAND_B | BAND_G | BAND_GN;14841484- else14851485- config_bands = BAND_A | BAND_AN;14861486-14871487- if (!((config_bands | priv->adapter->fw_bands) &14881488- ~priv->adapter->fw_bands))14891489- priv->adapter->config_bands = config_bands;14901490- }14911491- }1492147914931480 /* As this is new association, clear locally stored14941481 * keys and security related flags */···1693170616941707 if (cfg80211_get_chandef_type(¶ms->chandef) !=16951708 NL80211_CHAN_NO_HT)16961696- config_bands |= BAND_GN;17091709+ config_bands |= BAND_G | BAND_GN;16971710 } else {16981698- if (cfg80211_get_chandef_type(¶ms->chandef) !=17111711+ if (cfg80211_get_chandef_type(¶ms->chandef) ==16991712 NL80211_CHAN_NO_HT)17001713 config_bands = BAND_A;17011714 else
+1-1
drivers/net/wireless/mwifiex/pcie.c
···164164165165 if (pdev) {166166 card = (struct pcie_service_card *) pci_get_drvdata(pdev);167167- if (!card || card->adapter) {167167+ if (!card || !card->adapter) {168168 pr_err("Card or adapter structure is not valid\n");169169 return 0;170170 }
+24-11
drivers/net/wireless/mwifiex/sta_ioctl.c
···5656 */5757int mwifiex_wait_queue_complete(struct mwifiex_adapter *adapter)5858{5959- bool cancel_flag = false;6059 int status;6160 struct cmd_ctrl_node *cmd_queued;6261···6970 atomic_inc(&adapter->cmd_pending);70717172 /* Wait for completion */7272- wait_event_interruptible(adapter->cmd_wait_q.wait,7373- *(cmd_queued->condition));7474- if (!*(cmd_queued->condition))7575- cancel_flag = true;7676-7777- if (cancel_flag) {7878- mwifiex_cancel_pending_ioctl(adapter);7979- dev_dbg(adapter->dev, "cmd cancel\n");7373+ status = wait_event_interruptible(adapter->cmd_wait_q.wait,7474+ *(cmd_queued->condition));7575+ if (status) {7676+ dev_err(adapter->dev, "cmd_wait_q terminated: %d\n", status);7777+ return status;8078 }81798280 status = adapter->cmd_wait_q.status;···282286 ret = mwifiex_deauthenticate(priv, NULL);283287 if (ret)284288 goto done;289289+290290+ if (bss_desc) {291291+ u8 config_bands = 0;292292+293293+ if (mwifiex_band_to_radio_type((u8) bss_desc->bss_band)294294+ == HostCmd_SCAN_RADIO_TYPE_BG)295295+ config_bands = BAND_B | BAND_G | BAND_GN;296296+ else297297+ config_bands = BAND_A | BAND_AN;298298+299299+ if (!((config_bands | adapter->fw_bands) &300300+ ~adapter->fw_bands))301301+ adapter->config_bands = config_bands;302302+ }285303286304 ret = mwifiex_check_network_compatibility(priv, bss_desc);287305 if (ret)···506496 return false;507497 }508498509509- wait_event_interruptible(adapter->hs_activate_wait_q,510510- adapter->hs_activate_wait_q_woken);499499+ if (wait_event_interruptible(adapter->hs_activate_wait_q,500500+ adapter->hs_activate_wait_q_woken)) {501501+ dev_err(adapter->dev, "hs_activate_wait_q terminated\n");502502+ return false;503503+ }511504512505 return true;513506}
···167167168168config SSB_DRIVER_GPIO169169 bool "SSB GPIO driver"170170- depends on SSB171171- select GPIOLIB170170+ depends on SSB && GPIOLIB172171 help173172 Driver to provide access to the GPIO pins on the bus.174173
···352352353353 case BT_CONNECTED:354354 case BT_CONFIG:355355- if (sco_pi(sk)->conn) {355355+ if (sco_pi(sk)->conn->hcon) {356356 sk->sk_state = BT_DISCONN;357357 sco_sock_set_timer(sk, SCO_DISCONN_TIMEOUT);358358 hci_conn_put(sco_pi(sk)->conn->hcon);
+11-1
net/mac80211/cfg.c
···164164 sta = sta_info_get(sdata, mac_addr);165165 else166166 sta = sta_info_get_bss(sdata, mac_addr);167167- if (!sta) {167167+ /*168168+ * The ASSOC test makes sure the driver is ready to169169+ * receive the key. When wpa_supplicant has roamed170170+ * using FT, it attempts to set the key before171171+ * association has completed, this rejects that attempt172172+ * so it will set the key again after assocation.173173+ *174174+ * TODO: accept the key if we have a station entry and175175+ * add it to the device after the station.176176+ */177177+ if (!sta || !test_sta_flag(sta, WLAN_STA_ASSOC)) {168178 ieee80211_key_free(sdata->local, key);169179 err = -ENOENT;170180 goto out_unlock;
···102102 ieee80211_sta_reset_conn_monitor(sdata);103103}104104105105-void ieee80211_offchannel_stop_vifs(struct ieee80211_local *local,106106- bool offchannel_ps_enable)105105+void ieee80211_offchannel_stop_vifs(struct ieee80211_local *local)107106{108107 struct ieee80211_sub_if_data *sdata;109108···135136136137 if (sdata->vif.type != NL80211_IFTYPE_MONITOR) {137138 netif_tx_stop_all_queues(sdata->dev);138138- if (offchannel_ps_enable &&139139- (sdata->vif.type == NL80211_IFTYPE_STATION) &&139139+ if (sdata->vif.type == NL80211_IFTYPE_STATION &&140140 sdata->u.mgd.associated)141141 ieee80211_offchannel_ps_enable(sdata);142142 }···143145 mutex_unlock(&local->iflist_mtx);144146}145147146146-void ieee80211_offchannel_return(struct ieee80211_local *local,147147- bool offchannel_ps_disable)148148+void ieee80211_offchannel_return(struct ieee80211_local *local)148149{149150 struct ieee80211_sub_if_data *sdata;150151···162165 continue;163166164167 /* Tell AP we're back */165165- if (offchannel_ps_disable &&166166- sdata->vif.type == NL80211_IFTYPE_STATION) {167167- if (sdata->u.mgd.associated)168168- ieee80211_offchannel_ps_disable(sdata);169169- }168168+ if (sdata->vif.type == NL80211_IFTYPE_STATION &&169169+ sdata->u.mgd.associated)170170+ ieee80211_offchannel_ps_disable(sdata);170171171172 if (sdata->vif.type != NL80211_IFTYPE_MONITOR) {172173 /*···383388 local->tmp_channel = NULL;384389 ieee80211_hw_config(local, 0);385390386386- ieee80211_offchannel_return(local, true);391391+ ieee80211_offchannel_return(local);387392 }388393389394 ieee80211_recalc_idle(local);
+5-10
net/mac80211/scan.c
···291291 if (!was_hw_scan) {292292 ieee80211_configure_filter(local);293293 drv_sw_scan_complete(local);294294- ieee80211_offchannel_return(local, true);294294+ ieee80211_offchannel_return(local);295295 }296296297297 ieee80211_recalc_idle(local);···340340 local->next_scan_state = SCAN_DECISION;341341 local->scan_channel_idx = 0;342342343343- ieee80211_offchannel_stop_vifs(local, true);343343+ ieee80211_offchannel_stop_vifs(local);344344345345 ieee80211_configure_filter(local);346346···677677 local->scan_channel = NULL;678678 ieee80211_hw_config(local, IEEE80211_CONF_CHANGE_CHANNEL);679679680680- /*681681- * Re-enable vifs and beaconing. Leave PS682682- * in off-channel state..will put that back683683- * on-channel at the end of scanning.684684- */685685- ieee80211_offchannel_return(local, false);680680+ /* disable PS */681681+ ieee80211_offchannel_return(local);686682687683 *next_delay = HZ / 5;688684 /* afterwards, resume scan & go to next channel */···688692static void ieee80211_scan_state_resume(struct ieee80211_local *local,689693 unsigned long *next_delay)690694{691691- /* PS already is in off-channel mode */692692- ieee80211_offchannel_stop_vifs(local, false);695695+ ieee80211_offchannel_stop_vifs(local);693696694697 if (local->ops->flush) {695698 drv_flush(local, false);
+6-3
net/mac80211/tx.c
···16731673 chanctx_conf =16741674 rcu_dereference(tmp_sdata->vif.chanctx_conf);16751675 }16761676- if (!chanctx_conf)16771677- goto fail_rcu;1678167616791679- chan = chanctx_conf->def.chan;16771677+ if (chanctx_conf)16781678+ chan = chanctx_conf->def.chan;16791679+ else if (!local->use_chanctx)16801680+ chan = local->_oper_channel;16811681+ else16821682+ goto fail_rcu;1680168316811684 /*16821685 * Frame injection is not allowed if beaconing is not allowed