pull request: wireless 2013-03-06
Subsystems (5)
Dave,
This time just passing along a big batch of fixes from Johannes...
For the mac80211 bits:
"Here I have fixes from Ben Greear for stray work items when deleting interfaces, another idle handling fix from Felix, a fix from Marco ro a mesh PS buffering crash and I have a fix for the VHT MCS calculation in association request frames and more nl80211 feature advertising removal as well as a workaround to increase the dump size if the SKB overhead is too large. For 3.10 I already have a complete fix queued, but that also requires (simple) userspace changes."
And for the iwlwifi bits:
"The patches from Dor fix a bunch of calibration issues in the new MVM driver, and Emmanuel has a number of fixes there as well. Also, we decided to disable 8k A-MSDU by default, so that's in there. My own patches are addressing an issue we found with the new devices but that seems to also exist on older ones, the DMA writeback the devices do can be delayed and cause issues. The fix is unfortunately relatively large and depends on two other changes (to not be hugely conflicting), but I think it's still worth it at this point."
As Johannes says, it is a bit large. But I hope it is still early enough in the cycle to make that worthwhile.
Please let me know if there are problems!
John
---
The following changes since commit 66d29cbc59433ba538922a9e958495156b31b83b:
benet: Wait f/w POST until timeout (2013-03-06 02:47:06 -0500)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless.git for-davem
for you to fetch changes up to 32cdd592b723fc88ecca699e550197cd48bb4ad6:
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless into for-davem (2013-03-06 10:21:17 -0500)
----------------------------------------------------------------
Ben Greear (2):
mac80211: stop timers before canceling work items
mac80211: Fix crash due to un-canceled work-items
Dor Shaish (3):
iwlwifi: mvm: Set valid TX antennas value before calib request
iwlwifi: mvm: Take the phy_cfg from the TLV value
iwlwifi: mvm: Remove overriding calibrations for the 7000 family
Emmanuel Grumbach (5):
iwlwifi: disable 8K A-MSDU by default
iwlwifi: mvm: restart the NIC of the cmd queue gets full
iwlwifi: mvm: ignore STOP_AGG when restarting
iwlwifi: mvm: update the rssi calculation
iwlwifi: mvm: don't warn on normal BAR sending
Felix Fietkau (1):
mac80211: another fix for idle handling in monitor mode
Johannes Berg (7):
nl80211: remove channel width and extended capa advertising
mac80211: really fix monitor mode channel reporting
iwlwifi: don't map complete commands bidirectionally
iwlwifi: rename IWL_MAX_CMD_TFDS to IWL_MAX_CMD_TBS_PER_TFD
iwlwifi: use coherent DMA memory for command header
nl80211: increase wiphy dump size dynamically
mac80211: fix VHT MCS calculation
John W. Linville (3):
Merge branch 'for-john' of git://git.kernel.org/.../jberg/mac80211
Merge branch 'for-john' of git://git.kernel.org/.../iwlwifi/iwlwifi-fixes
Merge branch 'master' of git://git.kernel.org/.../linville/wireless into for-davem
Marco Porsch (1):
mac80211: fix oops on mesh PS broadcast forwarding
drivers/net/wireless/iwlwifi/dvm/sta.c | 2 +- drivers/net/wireless/iwlwifi/iwl-devtrace.h | 2 +- drivers/net/wireless/iwlwifi/iwl-drv.c | 3 +- drivers/net/wireless/iwlwifi/iwl-modparams.h | 2 +- drivers/net/wireless/iwlwifi/iwl-trans.h | 20 +- drivers/net/wireless/iwlwifi/mvm/fw-api.h | 18 +- drivers/net/wireless/iwlwifi/mvm/fw.c | 133 +------------- drivers/net/wireless/iwlwifi/mvm/mvm.h | 3 +- drivers/net/wireless/iwlwifi/mvm/ops.c | 18 +- drivers/net/wireless/iwlwifi/mvm/rx.c | 37 ++-- drivers/net/wireless/iwlwifi/mvm/sta.c | 10 + drivers/net/wireless/iwlwifi/mvm/tx.c | 6 +- drivers/net/wireless/iwlwifi/pcie/internal.h | 34 +++- drivers/net/wireless/iwlwifi/pcie/rx.c | 14 +- drivers/net/wireless/iwlwifi/pcie/tx.c | 266 +++++++++++++-------------- net/mac80211/cfg.c | 21 ++- net/mac80211/iface.c | 6 + net/mac80211/mlme.c | 28 ++- net/mac80211/tx.c | 3 +- net/wireless/core.c | 3 +- net/wireless/nl80211.c | 51 +++-- 21 files changed, 299 insertions(+), 381 deletions(-)
drivers/net/wireless/iwlwifi/dvm/sta.c +1 -1
@@ -151,7 +151,7 @@ int iwl_send_add_sta(struct iwl_priv *priv, sta_id, sta->sta.addr, flags & CMD_ASYNC ? "a" : "");if (!(flags &CMD_ASYNC )) { - cmd.flags |=CMD_WANT_SKB |CMD_WANT_HCMD ; + cmd.flags |=CMD_WANT_SKB ;might_sleep (); }
drivers/net/wireless/iwlwifi/iwl-devtrace.h +1 -1
@@ -363,7 +363,7 @@ TRACE_EVENT(iwlwifi_dev_hcmd, __entry->flags = cmd->flags;memcpy (__get_dynamic_array (hcmd), hdr,sizeof (*hdr)); -for (i =0 ; i <IWL_MAX_CMD_TFDS ; i++) { +for (i =0 ; i <IWL_MAX_CMD_TBS_PER_TFD ; i++) {if (!cmd->len[i])continue ; memcpy((u8 *)__get_dynamic_array(hcmd) + offset,
drivers/net/wireless/iwlwifi/iwl-drv.c +1 -2
@@ -1102,7 +1102,6 @@ void iwl_drv_stop(struct iwl_drv *drv)/* shared module parameters */ struct iwl_mod_params iwlwifi_mod_params = { - .amsdu_size_8K =1 , .restart_fw =1 , .plcp_check = true, .bt_coex_active = true,
@@ -1207,7 +1206,7 @@ MODULE_PARM_DESC(11n_disable, "disable 11n functionality, bitmap: 1: full, 2: agg TX, 4: agg RX");module_param_named (amsdu_size_8K, iwlwifi_mod_params.amsdu_size_8K, int,S_IRUGO ); -MODULE_PARM_DESC (amsdu_size_8K,"enable 8K amsdu size" ); +MODULE_PARM_DESC (amsdu_size_8K,"enable 8K amsdu size (default 0)" );module_param_named (fw_restart, iwlwifi_mod_params.restart_fw, int,S_IRUGO );MODULE_PARM_DESC (fw_restart,"restart firmware in case of error" );
drivers/net/wireless/iwlwifi/iwl-modparams.h +1 -1
@@ -91,7 +91,7 @@ enum iwl_power_level {* @sw_crypto: using hardware encryption, default = 0 * @disable_11n: disable 11n capabilities, default = 0, * use IWL_DISABLE_HT_* constants -* @amsdu_size_8K: enable 8K amsdu size, default = 1 +* @amsdu_size_8K: enable 8K amsdu size, default = 0 * @restart_fw: restart firmware, default = 1 * @plcp_check: enable plcp health check, default = true * @wd_disable: enable stuck queue check, default = 0
drivers/net/wireless/iwlwifi/iwl-trans.h +9 -11
@@ -186,19 +186,13 @@ struct iwl_rx_packet {* @CMD_ASYNC: Return right away and don't want for the response * @CMD_WANT_SKB: valid only with CMD_SYNC. The caller needs the buffer of the * response. The caller needs to call iwl_free_resp when done. -* @CMD_WANT_HCMD: The caller needs to get the HCMD that was sent in the -* response handler. Chunks flagged by %IWL_HCMD_DFL_NOCOPY won't be -* copied. The pointer passed to the response handler is in the transport -* ownership and don't need to be freed by the op_mode. This also means -* that the pointer is invalidated after the op_mode's handler returns. * @CMD_ON_DEMAND: This command is sent by the test mode pipe. */ enum CMD_MODE {CMD_SYNC =0 ,CMD_ASYNC =BIT (0 ),CMD_WANT_SKB =BIT (1 ), -CMD_WANT_HCMD =BIT (2 ), -CMD_ON_DEMAND =BIT (3 ), +CMD_ON_DEMAND =BIT (2 ), };#define DEF_CMD_PAYLOAD_SIZE 320
@@ -217,7 +211,11 @@ struct iwl_device_cmd {#define TFD_MAX_PAYLOAD_SIZE (sizeof(struct iwl_device_cmd)) -#define IWL_MAX_CMD_TFDS 2 +/* +* number of transfer buffers (fragments) per transmit frame descriptor; +* this is just the driver's idea, the hardware supports 20 +*/ +#define IWL_MAX_CMD_TBS_PER_TFD 2/** * struct iwl_hcmd_dataflag - flag for each one of the chunks of the command
@@ -254,15 +252,15 @@ enum iwl_hcmd_dataflag {* @id: id of the host command */ struct iwl_host_cmd { -const void *data[IWL_MAX_CMD_TFDS ]; +const void *data[IWL_MAX_CMD_TBS_PER_TFD ];struct iwl_rx_packet *resp_pkt;unsigned long _rx_page_addr;u32 _rx_page_order;int handler_status;u32 flags; -u16 len[IWL_MAX_CMD_TFDS ]; -u8 dataflags[IWL_MAX_CMD_TFDS ]; +u16 len[IWL_MAX_CMD_TBS_PER_TFD ]; +u8 dataflags[IWL_MAX_CMD_TBS_PER_TFD ];u8 id; };
drivers/net/wireless/iwlwifi/mvm/fw-api.h +10 -8
@@ -762,18 +762,20 @@ struct iwl_phy_context_cmd {#define IWL_RX_INFO_PHY_CNT 8#define IWL_RX_INFO_AGC_IDX 1#define IWL_RX_INFO_RSSI_AB_IDX 2 -#define IWL_RX_INFO_RSSI_C_IDX 3 -#define IWL_OFDM_AGC_DB_MSK 0xfe00 -#define IWL_OFDM_AGC_DB_POS 9 +#define IWL_OFDM_AGC_A_MSK 0x0000007f +#define IWL_OFDM_AGC_A_POS 0 +#define IWL_OFDM_AGC_B_MSK 0x00003f80 +#define IWL_OFDM_AGC_B_POS 7 +#define IWL_OFDM_AGC_CODE_MSK 0x3fe00000 +#define IWL_OFDM_AGC_CODE_POS 20#define IWL_OFDM_RSSI_INBAND_A_MSK 0x00ff -#define IWL_OFDM_RSSI_ALLBAND_A_MSK 0xff00#define IWL_OFDM_RSSI_A_POS 0 +#define IWL_OFDM_RSSI_ALLBAND_A_MSK 0xff00 +#define IWL_OFDM_RSSI_ALLBAND_A_POS 8#define IWL_OFDM_RSSI_INBAND_B_MSK 0xff0000 -#define IWL_OFDM_RSSI_ALLBAND_B_MSK 0xff000000#define IWL_OFDM_RSSI_B_POS 16 -#define IWL_OFDM_RSSI_INBAND_C_MSK 0x00ff -#define IWL_OFDM_RSSI_ALLBAND_C_MSK 0xff00 -#define IWL_OFDM_RSSI_C_POS 0 +#define IWL_OFDM_RSSI_ALLBAND_B_MSK 0xff000000 +#define IWL_OFDM_RSSI_ALLBAND_B_POS 24/** * struct iwl_rx_phy_info - phy info
drivers/net/wireless/iwlwifi/mvm/fw.c +5 -128
172 lines not on this page · raw message
drivers/net/wireless/iwlwifi/mvm/mvm.h +2 -1
@@ -80,7 +80,8 @@#define IWL_INVALID_MAC80211_QUEUE 0xff#define IWL_MVM_MAX_ADDRESSES 2 -#define IWL_RSSI_OFFSET 44 +/* RSSI offset for WkP */ +#define IWL_RSSI_OFFSET 50enum iwl_mvm_tx_fifo {IWL_MVM_TX_FIFO_BK =0 ,
drivers/net/wireless/iwlwifi/mvm/ops.c +13 -5
@@ -624,12 +624,8 @@ static void iwl_mvm_free_skb(struct iwl_op_mode *op_mode, struct sk_buff *skb)ieee80211_free_txskb (mvm->hw, skb); } -static void iwl_mvm_nic_error (struct iwl_op_mode *op_mode) +static void iwl_mvm_nic_restart (struct iwl_mvm *mvm) { -struct iwl_mvm *mvm =IWL_OP_MODE_GET_MVM (op_mode); - -iwl_mvm_dump_nic_error_log (mvm); -iwl_abort_notification_waits (&mvm->notif_wait);/*
@@ -663,9 +659,21 @@ static void iwl_mvm_nic_error(struct iwl_op_mode *op_mode) } } +static void iwl_mvm_nic_error (struct iwl_op_mode *op_mode) +{ +struct iwl_mvm *mvm =IWL_OP_MODE_GET_MVM (op_mode); + +iwl_mvm_dump_nic_error_log (mvm); + +iwl_mvm_nic_restart (mvm); +} +static void iwl_mvm_cmd_queue_full (struct iwl_op_mode *op_mode) { +struct iwl_mvm *mvm =IWL_OP_MODE_GET_MVM (op_mode); +WARN_ON (1 ); +iwl_mvm_nic_restart (mvm); }static const struct iwl_op_mode_ops iwl_mvm_ops = {
drivers/net/wireless/iwlwifi/mvm/rx.c +23 -14
@@ -131,33 +131,42 @@ static void iwl_mvm_pass_packet_to_mac80211(struct iwl_mvm *mvm,static int iwl_mvm_calc_rssi (struct iwl_mvm *mvm,struct iwl_rx_phy_info *phy_info) { -u32 rssi_a, rssi_b, rssi_c, max_rssi, agc_db; +int rssi_a, rssi_b, rssi_a_dbm, rssi_b_dbm, max_rssi_dbm; +int rssi_all_band_a, rssi_all_band_b; +u32 agc_a, agc_b, max_agc;u32 val; -/* Find max rssi among 3 possible receivers. +/* Find max rssi among 2 possible receivers. * These values are measured by the Digital Signal Processor (DSP). * They should stay fairly constant even as the signal strength varies, * if the radio's Automatic Gain Control (AGC) is working right. * AGC value (see below) will provide the "interesting" info. */ + val =le32_to_cpu (phy_info->non_cfg_phy[IWL_RX_INFO_AGC_IDX ]); + agc_a = (val &IWL_OFDM_AGC_A_MSK ) >>IWL_OFDM_AGC_A_POS ; + agc_b = (val &IWL_OFDM_AGC_B_MSK ) >>IWL_OFDM_AGC_B_POS ; + max_agc =max_t (u32, agc_a, agc_b); + val =le32_to_cpu (phy_info->non_cfg_phy[IWL_RX_INFO_RSSI_AB_IDX ]); rssi_a = (val &IWL_OFDM_RSSI_INBAND_A_MSK ) >>IWL_OFDM_RSSI_A_POS ; rssi_b = (val &IWL_OFDM_RSSI_INBAND_B_MSK ) >>IWL_OFDM_RSSI_B_POS ; - val =le32_to_cpu (phy_info->non_cfg_phy[IWL_RX_INFO_RSSI_C_IDX ]); - rssi_c = (val &IWL_OFDM_RSSI_INBAND_C_MSK ) >>IWL_OFDM_RSSI_C_POS ; - - val =le32_to_cpu (phy_info->non_cfg_phy[IWL_RX_INFO_AGC_IDX ]); - agc_db = (val &IWL_OFDM_AGC_DB_MSK ) >>IWL_OFDM_AGC_DB_POS ; + rssi_all_band_a = (val &IWL_OFDM_RSSI_ALLBAND_A_MSK ) >> +IWL_OFDM_RSSI_ALLBAND_A_POS ; + rssi_all_band_b = (val &IWL_OFDM_RSSI_ALLBAND_B_MSK ) >> +IWL_OFDM_RSSI_ALLBAND_B_POS ; - max_rssi =max_t (u32, rssi_a, rssi_b); - max_rssi =max_t (u32, max_rssi, rssi_c); +/* +* dBm = rssi dB - agc dB - constant. +* Higher AGC (higher radio gain) means lower signal. +*/ + rssi_a_dbm = rssi_a -IWL_RSSI_OFFSET - agc_a; + rssi_b_dbm = rssi_b -IWL_RSSI_OFFSET - agc_b; + max_rssi_dbm =max_t (int, rssi_a_dbm, rssi_b_dbm); -IWL_DEBUG_STATS (mvm,"Rssi In A %d B %d C %d Max %d AGC dB %d\n" , - rssi_a, rssi_b, rssi_c, max_rssi, agc_db); +IWL_DEBUG_STATS (mvm,"Rssi In A %d B %d Max %d AGCA %d AGCB %d\n" , + rssi_a_dbm, rssi_b_dbm, max_rssi_dbm, agc_a, agc_b); -/* dBm = max_rssi dB - agc dB - constant. -* Higher AGC (higher radio gain) means lower signal. */ -return max_rssi - agc_db -IWL_RSSI_OFFSET ; +return max_rssi_dbm; }/*
drivers/net/wireless/iwlwifi/mvm/sta.c +10 -0
@@ -770,6 +770,16 @@ int iwl_mvm_sta_tx_agg_stop(struct iwl_mvm *mvm, struct ieee80211_vif *vif,u16 txq_id;int err; + +/* +* If mac80211 is cleaning its state, then say that we finished since +* our state has been cleared anyway. +*/ +if (test_bit (IWL_MVM_STATUS_IN_HW_RESTART , &mvm->status)) { +ieee80211_stop_tx_ba_cb_irqsafe (vif, sta->addr, tid); +return 0 ; + } +spin_lock_bh (&mvmsta->lock); txq_id = tid_data->txq_id;
drivers/net/wireless/iwlwifi/mvm/tx.c +1 -5
@@ -607,12 +607,8 @@ static void iwl_mvm_rx_tx_cmd_single(struct iwl_mvm *mvm,/* Single frame failure in an AMPDU queue => send BAR */ if (txq_id >=IWL_FIRST_AMPDU_QUEUE && - !(info->flags &IEEE80211_TX_STAT_ACK )) { -/* there must be only one skb in the skb_list */ -WARN_ON_ONCE (skb_freed >1 || - !skb_queue_empty (&skbs)); + !(info->flags &IEEE80211_TX_STAT_ACK )) info->flags |=IEEE80211_TX_STAT_AMPDU_NO_BACK ; - }/* W/A FW bug: seq_ctl is wrong when the queue is flushed */ if (status ==TX_STATUS_FAIL_FIFO_FLUSHED ) {
drivers/net/wireless/iwlwifi/pcie/internal.h +25 -9
@@ -137,10 +137,6 @@ static inline int iwl_queue_dec_wrap(int index, int n_bd)struct iwl_cmd_meta {/* only for SYNC commands, iff the reply skb is wanted */ struct iwl_host_cmd *source; - -DEFINE_DMA_UNMAP_ADDR (mapping); -DEFINE_DMA_UNMAP_LEN (len); -u32 flags; };
@@ -185,25 +181,36 @@ struct iwl_queue {/* * The FH will write back to the first TB only, so we need * to copy some data into the buffer regardless of whether -* it should be mapped or not. This indicates how much to -* copy, even for HCMDs it must be big enough to fit the -* DRAM scratch from the TX cmd, at least 16 bytes. +* it should be mapped or not. This indicates how big the +* first TB must be to include the scratch buffer. Since +* the scratch is 4 bytes at offset 12, it's 16 now. If we +* make it bigger then allocations will be bigger and copy +* slower, so that's probably not useful. */ -#define IWL_HCMD_MIN_COPY_SIZE 16 +#define IWL_HCMD_SCRATCHBUF_SIZE 16struct iwl_pcie_txq_entry {struct iwl_device_cmd *cmd; -struct iwl_device_cmd *copy_cmd;struct sk_buff *skb;/* buffer to free after command completes */ const void *free_buf;struct iwl_cmd_meta meta; }; +struct iwl_pcie_txq_scratch_buf { +struct iwl_cmd_header hdr; +u8 buf[8 ]; +__le32 scratch; +}; +/** * struct iwl_txq - Tx Queue for DMA * @q: generic Rx/Tx queue descriptor * @tfds: transmit frame descriptors (DMA memory) +* @scratchbufs: start of command headers, including scratch buffers, for +* the writeback -- this is DMA memory and an array holding one buffer +* for each command on the queue +* @scratchbufs_dma: DMA address for the scratchbufs start * @entries: transmit entries (driver state) * @lock: queue lock * @stuck_timer: timer that fires if queue gets stuck
@@ -217,6 +224,8 @@ struct iwl_pcie_txq_entry {struct iwl_txq {struct iwl_queue q;struct iwl_tfd *tfds; +struct iwl_pcie_txq_scratch_buf *scratchbufs; +dma_addr_t scratchbufs_dma;struct iwl_pcie_txq_entry *entries;spinlock_t lock;struct timer_list stuck_timer;
@@ -225,6 +234,13 @@ struct iwl_txq {u8 active; }; +static inline dma_addr_t +iwl_pcie_get_scratchbuf_dma (struct iwl_txq *txq,int idx) +{ +return txq->scratchbufs_dma + +sizeof (struct iwl_pcie_txq_scratch_buf ) * idx; +} +/** * struct iwl_trans_pcie - PCIe transport specific data * @rxq: all the RX queue data
drivers/net/wireless/iwlwifi/pcie/rx.c +3 -11
@@ -637,22 +637,14 @@ static void iwl_pcie_rx_handle_rb(struct iwl_trans *trans, index =SEQ_TO_INDEX (sequence); cmd_index =get_cmd_index (&txq->q, index); -if (reclaim) { -struct iwl_pcie_txq_entry *ent; - ent = &txq->entries[cmd_index]; - cmd = ent->copy_cmd; -WARN_ON_ONCE (!cmd && ent->meta.flags &CMD_WANT_HCMD ); - }else { +if (reclaim) + cmd = txq->entries[cmd_index].cmd; +else cmd =NULL ; - } err =iwl_op_mode_rx (trans->op_mode, &rxcb, cmd);if (reclaim) { -/* The original command isn't needed any more */ -kfree (txq->entries[cmd_index].copy_cmd); - txq->entries[cmd_index].copy_cmd =NULL ; -/* nor is the duplicated part of the command */ kfree (txq->entries[cmd_index].free_buf); txq->entries[cmd_index].free_buf =NULL ; }
drivers/net/wireless/iwlwifi/pcie/tx.c +124 -142
441 lines not on this page · raw message
net/mac80211/cfg.c +13 -8
@@ -3290,14 +3290,19 @@ static int ieee80211_cfg_get_channel(struct wiphy *wiphy,int ret = -ENODATA ;rcu_read_lock (); -if (local->use_chanctx) { - chanctx_conf =rcu_dereference (sdata->vif.chanctx_conf); -if (chanctx_conf) { - *chandef = chanctx_conf->def; - ret =0 ; - } - }else if (local->open_count == local->monitors) { - *chandef = local->monitor_chandef; + chanctx_conf =rcu_dereference (sdata->vif.chanctx_conf); +if (chanctx_conf) { + *chandef = chanctx_conf->def; + ret =0 ; + }else if (local->open_count >0 && + local->open_count == local->monitors && + sdata->vif.type ==NL80211_IFTYPE_MONITOR ) { +if (local->use_chanctx) + *chandef = local->monitor_chandef; +else +cfg80211_chandef_create (chandef, + local->_oper_channel, + local->_oper_channel_type); ret =0 ; }rcu_read_unlock ();
net/mac80211/iface.c +6 -0
@@ -541,6 +541,9 @@ int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up)ieee80211_adjust_monitor_flags (sdata,1 );ieee80211_configure_filter (local); +mutex_lock (&local->mtx); +ieee80211_recalc_idle (local); +mutex_unlock (&local->mtx);netif_carrier_on (dev);break ;
@@ -812,6 +815,9 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata,ieee80211_adjust_monitor_flags (sdata,-1 );ieee80211_configure_filter (local); +mutex_lock (&local->mtx); +ieee80211_recalc_idle (local); +mutex_unlock (&local->mtx);break ;case NL80211_IFTYPE_P2P_DEVICE :/* relies on synchronize_rcu() below */
net/mac80211/mlme.c +23 -5
@@ -647,6 +647,9 @@ static void ieee80211_add_vht_ie(struct ieee80211_sub_if_data *sdata, our_mcs = (le16_to_cpu (vht_cap.vht_mcs.rx_mcs_map) & mask) >> shift; +if (our_mcs ==IEEE80211_VHT_MCS_NOT_SUPPORTED ) +continue ; +switch (ap_mcs) {default :if (our_mcs <= ap_mcs)
@@ -3503,6 +3506,14 @@ void ieee80211_sta_quiesce(struct ieee80211_sub_if_data *sdata)struct ieee80211_if_managed *ifmgd = &sdata->u.mgd;/* +* Stop timers before deleting work items, as timers +* could race and re-add the work-items. They will be +* re-established on connection. +*/ +del_timer_sync (&ifmgd->conn_mon_timer); +del_timer_sync (&ifmgd->bcn_mon_timer); + +/* * we need to use atomic bitops for the running bits * only because both timers might fire at the same * time -- the code here is properly synchronised.
@@ -3516,13 +3527,9 @@ void ieee80211_sta_quiesce(struct ieee80211_sub_if_data *sdata)if (del_timer_sync (&ifmgd->timer))set_bit (TMR_RUNNING_TIMER , &ifmgd->timers_running); -cancel_work_sync (&ifmgd->chswitch_work);if (del_timer_sync (&ifmgd->chswitch_timer))set_bit (TMR_RUNNING_CHANSW , &ifmgd->timers_running); - -/* these will just be re-established on connection */ -del_timer_sync (&ifmgd->conn_mon_timer); -del_timer_sync (&ifmgd->bcn_mon_timer); +cancel_work_sync (&ifmgd->chswitch_work); }void ieee80211_sta_restart (struct ieee80211_sub_if_data *sdata)
@@ -4315,6 +4322,17 @@ void ieee80211_mgd_stop(struct ieee80211_sub_if_data *sdata) {struct ieee80211_if_managed *ifmgd = &sdata->u.mgd; +/* +* Make sure some work items will not run after this, +* they will not do anything but might not have been +* cancelled when disconnecting. +*/ +cancel_work_sync (&ifmgd->monitor_work); +cancel_work_sync (&ifmgd->beacon_connection_loss_work); +cancel_work_sync (&ifmgd->request_smps_work); +cancel_work_sync (&ifmgd->csa_connection_drop_work); +cancel_work_sync (&ifmgd->chswitch_work); +mutex_lock (&ifmgd->mtx);if (ifmgd->assoc_data)ieee80211_destroy_assoc_data (sdata, false);
net/mac80211/tx.c +2 -1
@@ -2745,7 +2745,8 @@ ieee80211_get_buffered_bc(struct ieee80211_hw *hw,cpu_to_le16 (IEEE80211_FCTL_MOREDATA ); } - sdata =IEEE80211_DEV_TO_SUB_IF (skb->dev); +if (sdata->vif.type ==NL80211_IFTYPE_AP_VLAN ) + sdata =IEEE80211_DEV_TO_SUB_IF (skb->dev);if (!ieee80211_tx_prepare (sdata, &tx, skb))break ;dev_kfree_skb_any (skb);
net/wireless/core.c +1 -2
@@ -367,8 +367,7 @@ struct wiphy *wiphy_new(const struct cfg80211_ops *ops, int sizeof_priv) rdev->wiphy.rts_threshold = (u32) -1 ; rdev->wiphy.coverage_class =0 ; - rdev->wiphy.features =NL80211_FEATURE_SCAN_FLUSH | -NL80211_FEATURE_ADVERTISE_CHAN_LIMITS ; + rdev->wiphy.features =NL80211_FEATURE_SCAN_FLUSH ;return &rdev->wiphy; }
net/wireless/nl80211.c +25 -26
81 lines not on this page · raw message
Signature · 2 lines
John W. Linville Someday the world will need a hero, and you [email protected] might be all we have. Be ready.
David Miller
maintainerFrom: "John W. Linville" <[email protected]>
Date: Wed, 6 Mar 2013 14:29:14 -0500
Quoted 2 lines
As Johannes says, it is a bit large. But I hope it is still early enough in the cycle to make that worthwhile.
It's quite sizable, but I guess better during -rc1 than -rc6 or -rc7 :-)
Pulled, thanks John.