All of lore.kernel.org
 help / color / mirror / Atom feed
* pull-request: iwlwifi-fixes 2013-07-26
@ 2013-07-26  8:17 Johannes Berg
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
  2013-07-29 18:45 ` pull-request: iwlwifi-fixes 2013-07-26 John W. Linville
  0 siblings, 2 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:17 UTC (permalink / raw)
  To: John Linville; +Cc: linux-wireless

[-- Attachment #1: Type: text/plain, Size: 2055 bytes --]

John,

Yet some more fixes - we're adding tests and are doing a debug cycle
with them.

We have a scan fix for passive channels, a new PCI device ID for an old
device, a NIC reset fix, an RF-Kill fix, a fix for powersave when GO
interfaces are present as well as an aggregation session fix (for a
corner case) and a workaround for a firmware design issue - it only
supports a single GTK in D3.

Let me know if there's any problem.

johannes



The following changes since commit a590ad411891de551e6de1b51ea635c0484148d6:

  iwlwifi: mvm: remove extra SSID from probe request (2013-07-16 13:55:15 +0300)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-fixes.git for-john

for you to fetch changes up to a53ee0a308b16e392e0219c585b10f329345766b:

  iwlwifi: pcie: clear RFKILL interrupt in AMPG (2013-07-26 10:07:10 +0200)

----------------------------------------------------------------
David Spinadel (1):
      iwlwifi: mvm: set SSID bits for passive channels

Emmanuel Grumbach (3):
      iwlwifi: add DELL SKU for 5150 HMC
      iwlwifi: pcie: reset the NIC before the bring up
      iwlwifi: pcie: clear RFKILL interrupt in AMPG

Ilan Peer (1):
      iwlwifi: mvm: Disable managed PS when GO is added

Johannes Berg (2):
      iwlwifi: mvm: use only a single GTK in D3
      iwlwifi: mvm: fix flushing not started aggregation sessions

 drivers/net/wireless/iwlwifi/iwl-prph.h        |  2 ++
 drivers/net/wireless/iwlwifi/mvm/d3.c          | 15 ++++++---
 drivers/net/wireless/iwlwifi/mvm/fw-api-scan.h |  1 -
 drivers/net/wireless/iwlwifi/mvm/mac80211.c    | 42 +++++++++++++-------------
 drivers/net/wireless/iwlwifi/mvm/scan.c        | 11 ++-----
 drivers/net/wireless/iwlwifi/mvm/sta.c         | 11 +++++--
 drivers/net/wireless/iwlwifi/pcie/drv.c        |  1 +
 drivers/net/wireless/iwlwifi/pcie/rx.c         |  8 +++++
 drivers/net/wireless/iwlwifi/pcie/trans.c      |  5 +++
 9 files changed, 57 insertions(+), 39 deletions(-)


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC
  2013-07-26  8:17 pull-request: iwlwifi-fixes 2013-07-26 Johannes Berg
@ 2013-07-26  8:19 ` Johannes Berg
  2013-07-26  8:19   ` [PATCH 2/7] iwlwifi: mvm: use only a single GTK in D3 Johannes Berg
                     ` (5 more replies)
  2013-07-29 18:45 ` pull-request: iwlwifi-fixes 2013-07-26 John W. Linville
  1 sibling, 6 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:19 UTC (permalink / raw)
  To: linux-wireless; +Cc: Emmanuel Grumbach

From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>

This SKU was missing in the list of supported devices

https://bugzilla.kernel.org/show_bug.cgi?id=60577

Cc: <stable@vger.kernel.org> [all versions]
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/iwlwifi/pcie/drv.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/wireless/iwlwifi/pcie/drv.c b/drivers/net/wireless/iwlwifi/pcie/drv.c
index 81f3ea5..ff13458 100644
--- a/drivers/net/wireless/iwlwifi/pcie/drv.c
+++ b/drivers/net/wireless/iwlwifi/pcie/drv.c
@@ -130,6 +130,7 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = {
 	{IWL_PCI_DEVICE(0x423C, 0x1306, iwl5150_abg_cfg)}, /* Half Mini Card */
 	{IWL_PCI_DEVICE(0x423C, 0x1221, iwl5150_agn_cfg)}, /* Mini Card */
 	{IWL_PCI_DEVICE(0x423C, 0x1321, iwl5150_agn_cfg)}, /* Half Mini Card */
+	{IWL_PCI_DEVICE(0x423C, 0x1326, iwl5150_abg_cfg)}, /* Half Mini Card */
 
 	{IWL_PCI_DEVICE(0x423D, 0x1211, iwl5150_agn_cfg)}, /* Mini Card */
 	{IWL_PCI_DEVICE(0x423D, 0x1311, iwl5150_agn_cfg)}, /* Half Mini Card */
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 2/7] iwlwifi: mvm: use only a single GTK in D3
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
@ 2013-07-26  8:19   ` Johannes Berg
  2013-07-26  8:19   ` [PATCH 3/7] iwlwifi: mvm: set SSID bits for passive channels Johannes Berg
                     ` (4 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:19 UTC (permalink / raw)
  To: linux-wireless; +Cc: Johannes Berg

From: Johannes Berg <johannes.berg@intel.com>

Unfortunately, the firmware only supports replay counters for
a single GTK in D3, so that we should only upload the last
key and use its replay counters. Since mac80211 key iteration
will walk through the keys in order of their addition, simply
use the same HW key index (1) for all GTKs, thus overwriting
previous ones with newer ones. The replay counters for it are
already used.

Reviewed-by: Yaron Vaknin <Yaron.Vaknin@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/iwlwifi/mvm/d3.c | 15 ++++++++++-----
 1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/drivers/net/wireless/iwlwifi/mvm/d3.c b/drivers/net/wireless/iwlwifi/mvm/d3.c
index 7e5e5c2..83da884 100644
--- a/drivers/net/wireless/iwlwifi/mvm/d3.c
+++ b/drivers/net/wireless/iwlwifi/mvm/d3.c
@@ -134,7 +134,7 @@ struct wowlan_key_data {
 	struct iwl_wowlan_rsc_tsc_params_cmd *rsc_tsc;
 	struct iwl_wowlan_tkip_params_cmd *tkip;
 	bool error, use_rsc_tsc, use_tkip;
-	int gtk_key_idx;
+	int wep_key_idx;
 };
 
 static void iwl_mvm_wowlan_program_keys(struct ieee80211_hw *hw,
@@ -188,8 +188,8 @@ static void iwl_mvm_wowlan_program_keys(struct ieee80211_hw *hw,
 			wkc.wep_key.key_offset = 0;
 		} else {
 			/* others start at 1 */
-			data->gtk_key_idx++;
-			wkc.wep_key.key_offset = data->gtk_key_idx;
+			data->wep_key_idx++;
+			wkc.wep_key.key_offset = data->wep_key_idx;
 		}
 
 		ret = iwl_mvm_send_cmd_pdu(mvm, WEP_KEY, CMD_SYNC,
@@ -316,8 +316,13 @@ static void iwl_mvm_wowlan_program_keys(struct ieee80211_hw *hw,
 		mvm->ptk_ivlen = key->iv_len;
 		mvm->ptk_icvlen = key->icv_len;
 	} else {
-		data->gtk_key_idx++;
-		key->hw_key_idx = data->gtk_key_idx;
+		/*
+		 * firmware only supports TSC/RSC for a single key,
+		 * so if there are multiple keep overwriting them
+		 * with new ones -- this relies on mac80211 doing
+		 * list_add_tail().
+		 */
+		key->hw_key_idx = 1;
 		mvm->gtk_ivlen = key->iv_len;
 		mvm->gtk_icvlen = key->icv_len;
 	}
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 3/7] iwlwifi: mvm: set SSID bits for passive channels
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
  2013-07-26  8:19   ` [PATCH 2/7] iwlwifi: mvm: use only a single GTK in D3 Johannes Berg
@ 2013-07-26  8:19   ` Johannes Berg
  2013-07-26  8:19   ` [PATCH 4/7] iwlwifi: pcie: reset the NIC before the bring up Johannes Berg
                     ` (3 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:19 UTC (permalink / raw)
  To: linux-wireless; +Cc: David Spinadel

From: David Spinadel <david.spinadel@intel.com>

Set SSID bitmap for direct scan even on passive channels,
for the passive-to-active feature. Without this patch only
the SSID from probe request template is sent on passive
channels, after passive-to-active switching, causing us to
not find all desired networks.

Remove the unused passive scan mask constant.

Cc: stable@vger.kernel.org
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: David Spinadel <david.spinadel@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/iwlwifi/mvm/fw-api-scan.h |  1 -
 drivers/net/wireless/iwlwifi/mvm/scan.c        | 11 ++---------
 2 files changed, 2 insertions(+), 10 deletions(-)

diff --git a/drivers/net/wireless/iwlwifi/mvm/fw-api-scan.h b/drivers/net/wireless/iwlwifi/mvm/fw-api-scan.h
index b60d141..365095a 100644
--- a/drivers/net/wireless/iwlwifi/mvm/fw-api-scan.h
+++ b/drivers/net/wireless/iwlwifi/mvm/fw-api-scan.h
@@ -69,7 +69,6 @@
 /* Scan Commands, Responses, Notifications */
 
 /* Masks for iwl_scan_channel.type flags */
-#define SCAN_CHANNEL_TYPE_PASSIVE	0
 #define SCAN_CHANNEL_TYPE_ACTIVE	BIT(0)
 #define SCAN_CHANNEL_NARROW_BAND	BIT(22)
 
diff --git a/drivers/net/wireless/iwlwifi/mvm/scan.c b/drivers/net/wireless/iwlwifi/mvm/scan.c
index 268f027..acdff6b 100644
--- a/drivers/net/wireless/iwlwifi/mvm/scan.c
+++ b/drivers/net/wireless/iwlwifi/mvm/scan.c
@@ -178,19 +178,12 @@ static void iwl_mvm_scan_fill_channels(struct iwl_scan_cmd *cmd,
 	struct iwl_scan_channel *chan = (struct iwl_scan_channel *)
 		(cmd->data + le16_to_cpu(cmd->tx_cmd.len));
 	int i;
-	__le32 chan_type_value;
-
-	if (req->n_ssids > 0)
-		chan_type_value = cpu_to_le32(BIT(req->n_ssids) - 1);
-	else
-		chan_type_value = SCAN_CHANNEL_TYPE_PASSIVE;
 
 	for (i = 0; i < cmd->channel_count; i++) {
 		chan->channel = cpu_to_le16(req->channels[i]->hw_value);
+		chan->type = cpu_to_le32(BIT(req->n_ssids) - 1);
 		if (req->channels[i]->flags & IEEE80211_CHAN_PASSIVE_SCAN)
-			chan->type = SCAN_CHANNEL_TYPE_PASSIVE;
-		else
-			chan->type = chan_type_value;
+			chan->type &= cpu_to_le32(~SCAN_CHANNEL_TYPE_ACTIVE);
 		chan->active_dwell = cpu_to_le16(active_dwell);
 		chan->passive_dwell = cpu_to_le16(passive_dwell);
 		chan->iteration_count = cpu_to_le16(1);
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 4/7] iwlwifi: pcie: reset the NIC before the bring up
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
  2013-07-26  8:19   ` [PATCH 2/7] iwlwifi: mvm: use only a single GTK in D3 Johannes Berg
  2013-07-26  8:19   ` [PATCH 3/7] iwlwifi: mvm: set SSID bits for passive channels Johannes Berg
@ 2013-07-26  8:19   ` Johannes Berg
  2013-07-26  8:19   ` [PATCH 5/7] iwlwifi: mvm: Disable managed PS when GO is added Johannes Berg
                     ` (2 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:19 UTC (permalink / raw)
  To: linux-wireless; +Cc: Emmanuel Grumbach

From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>

This allows to clean all kinds of bad state it might be in.
This solves situation where HW RFkill was switched while
the NIC was offline.
Until now, we relied on the firmware to do clean the
interrupt, but new firmwares don't do that any more.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/iwlwifi/pcie/trans.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/net/wireless/iwlwifi/pcie/trans.c b/drivers/net/wireless/iwlwifi/pcie/trans.c
index 826c156..96cfcdd 100644
--- a/drivers/net/wireless/iwlwifi/pcie/trans.c
+++ b/drivers/net/wireless/iwlwifi/pcie/trans.c
@@ -670,6 +670,11 @@ static int iwl_trans_pcie_start_hw(struct iwl_trans *trans)
 		return err;
 	}
 
+	/* Reset the entire device */
+	iwl_set_bit(trans, CSR_RESET, CSR_RESET_REG_FLAG_SW_RESET);
+
+	usleep_range(10, 15);
+
 	iwl_pcie_apm_init(trans);
 
 	/* From now on, the op_mode will be kept updated about RF kill state */
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 5/7] iwlwifi: mvm: Disable managed PS when GO is added
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
                     ` (2 preceding siblings ...)
  2013-07-26  8:19   ` [PATCH 4/7] iwlwifi: pcie: reset the NIC before the bring up Johannes Berg
@ 2013-07-26  8:19   ` Johannes Berg
  2013-07-26  8:19   ` [PATCH 6/7] iwlwifi: mvm: fix flushing not started aggregation sessions Johannes Berg
  2013-07-26  8:19   ` [PATCH 7/7] iwlwifi: pcie: clear RFKILL interrupt in AMPG Johannes Berg
  5 siblings, 0 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:19 UTC (permalink / raw)
  To: linux-wireless; +Cc: Ilan Peer

From: Ilan Peer <ilan.peer@intel.com>

The managed interface PS was not disabled when a GO interface
was added. As a consequence, when the station VMAC was in PS,
the GO also was not on the medium. Fix this.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/iwlwifi/mvm/mac80211.c | 42 ++++++++++++++---------------
 1 file changed, 21 insertions(+), 21 deletions(-)

diff --git a/drivers/net/wireless/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/iwlwifi/mvm/mac80211.c
index 1eedc42..f19baf0 100644
--- a/drivers/net/wireless/iwlwifi/mvm/mac80211.c
+++ b/drivers/net/wireless/iwlwifi/mvm/mac80211.c
@@ -512,6 +512,27 @@ static int iwl_mvm_mac_add_interface(struct ieee80211_hw *hw,
 		goto out_unlock;
 
 	/*
+	 * TODO: remove this temporary code.
+	 * Currently MVM FW supports power management only on single MAC.
+	 * If new interface added, disable PM on existing interface.
+	 * P2P device is a special case, since it is handled by FW similary to
+	 * scan. If P2P deviced is added, PM remains enabled on existing
+	 * interface.
+	 * Note: the method below does not count the new interface being added
+	 * at this moment.
+	 */
+	if (vif->type != NL80211_IFTYPE_P2P_DEVICE)
+		mvm->vif_count++;
+	if (mvm->vif_count > 1) {
+		IWL_DEBUG_MAC80211(mvm,
+				   "Disable power on existing interfaces\n");
+		ieee80211_iterate_active_interfaces_atomic(
+					    mvm->hw,
+					    IEEE80211_IFACE_ITER_NORMAL,
+					    iwl_mvm_pm_disable_iterator, mvm);
+	}
+
+	/*
 	 * The AP binding flow can be done only after the beacon
 	 * template is configured (which happens only in the mac80211
 	 * start_ap() flow), and adding the broadcast station can happen
@@ -534,27 +555,6 @@ static int iwl_mvm_mac_add_interface(struct ieee80211_hw *hw,
 		goto out_unlock;
 	}
 
-	/*
-	 * TODO: remove this temporary code.
-	 * Currently MVM FW supports power management only on single MAC.
-	 * If new interface added, disable PM on existing interface.
-	 * P2P device is a special case, since it is handled by FW similary to
-	 * scan. If P2P deviced is added, PM remains enabled on existing
-	 * interface.
-	 * Note: the method below does not count the new interface being added
-	 * at this moment.
-	 */
-	if (vif->type != NL80211_IFTYPE_P2P_DEVICE)
-		mvm->vif_count++;
-	if (mvm->vif_count > 1) {
-		IWL_DEBUG_MAC80211(mvm,
-				   "Disable power on existing interfaces\n");
-		ieee80211_iterate_active_interfaces_atomic(
-					    mvm->hw,
-					    IEEE80211_IFACE_ITER_NORMAL,
-					    iwl_mvm_pm_disable_iterator, mvm);
-	}
-
 	ret = iwl_mvm_mac_ctxt_add(mvm, vif);
 	if (ret)
 		goto out_release;
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 6/7] iwlwifi: mvm: fix flushing not started aggregation sessions
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
                     ` (3 preceding siblings ...)
  2013-07-26  8:19   ` [PATCH 5/7] iwlwifi: mvm: Disable managed PS when GO is added Johannes Berg
@ 2013-07-26  8:19   ` Johannes Berg
  2013-07-26  8:19   ` [PATCH 7/7] iwlwifi: pcie: clear RFKILL interrupt in AMPG Johannes Berg
  5 siblings, 0 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:19 UTC (permalink / raw)
  To: linux-wireless; +Cc: Johannes Berg

From: Johannes Berg <johannes.berg@intel.com>

When a not fully started aggregation session is destroyed
and flushed, we get a warning, e.g.

  WARNING: at drivers/net/wireless/iwlwifi/pcie/tx.c:1142 iwl_trans_pcie_txq_disable+0x11c/0x160
  queue 16 not used
  Modules linked in: [...]
  Pid: 5135, comm: hostapd Tainted: G        W  O 3.5.0 #10
  Call Trace:
  wlan0: driver sets block=0 for sta 00:03:7f:10:44:d3
   [<ffffffff81036492>] warn_slowpath_common+0x72/0xa0
   [<ffffffff81036577>] warn_slowpath_fmt+0x47/0x50
   [<ffffffffa0368d6c>] iwl_trans_pcie_txq_disable+0x11c/0x160 [iwlwifi]
   [<ffffffffa03a2099>] iwl_mvm_sta_tx_agg_flush+0xe9/0x150 [iwlmvm]
   [<ffffffffa0396c43>] iwl_mvm_mac_ampdu_action+0xf3/0x1e0 [iwlmvm]
   [<ffffffffa0293ad3>] ___ieee80211_stop_tx_ba_session+0x193/0x920 [mac80211]
   [<ffffffffa0294ed8>] __ieee80211_stop_tx_ba_session+0x48/0x70 [mac80211]
   [<ffffffffa029159f>] ieee80211_sta_tear_down_BA_sessions+0x4f/0x80 [mac80211]
   [<ffffffffa028a686>] __sta_info_destroy+0x66/0x370 [mac80211]
   [<ffffffffa028abb4>] sta_info_destroy_addr_bss+0x44/0x70 [mac80211]
   [<ffffffffa02a3e26>] ieee80211_del_station+0x26/0x50 [mac80211]
   [<ffffffffa01e6395>] nl80211_del_station+0x85/0x200 [cfg80211]

when a station deauthenticated from us without fully setting
up the aggregation session.

Fix this by checking the aggregation state before removing
the hardware queue.

Cc: stable@vger.kernel.org
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/iwlwifi/mvm/sta.c | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/iwlwifi/mvm/sta.c b/drivers/net/wireless/iwlwifi/mvm/sta.c
index 85d4bbe..563f559 100644
--- a/drivers/net/wireless/iwlwifi/mvm/sta.c
+++ b/drivers/net/wireless/iwlwifi/mvm/sta.c
@@ -915,6 +915,7 @@ int iwl_mvm_sta_tx_agg_flush(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
 	struct iwl_mvm_sta *mvmsta = (void *)sta->drv_priv;
 	struct iwl_mvm_tid_data *tid_data = &mvmsta->tid_data[tid];
 	u16 txq_id;
+	enum iwl_mvm_agg_state old_state;
 
 	/*
 	 * First set the agg state to OFF to avoid calling
@@ -924,13 +925,17 @@ int iwl_mvm_sta_tx_agg_flush(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
 	txq_id = tid_data->txq_id;
 	IWL_DEBUG_TX_QUEUES(mvm, "Flush AGG: sta %d tid %d q %d state %d\n",
 			    mvmsta->sta_id, tid, txq_id, tid_data->state);
+	old_state = tid_data->state;
 	tid_data->state = IWL_AGG_OFF;
 	spin_unlock_bh(&mvmsta->lock);
 
-	if (iwl_mvm_flush_tx_path(mvm, BIT(txq_id), true))
-		IWL_ERR(mvm, "Couldn't flush the AGG queue\n");
+	if (old_state >= IWL_AGG_ON) {
+		if (iwl_mvm_flush_tx_path(mvm, BIT(txq_id), true))
+			IWL_ERR(mvm, "Couldn't flush the AGG queue\n");
+
+		iwl_trans_txq_disable(mvm->trans, tid_data->txq_id);
+	}
 
-	iwl_trans_txq_disable(mvm->trans, tid_data->txq_id);
 	mvm->queue_to_mac80211[tid_data->txq_id] =
 				IWL_INVALID_MAC80211_QUEUE;
 
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 7/7] iwlwifi: pcie: clear RFKILL interrupt in AMPG
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
                     ` (4 preceding siblings ...)
  2013-07-26  8:19   ` [PATCH 6/7] iwlwifi: mvm: fix flushing not started aggregation sessions Johannes Berg
@ 2013-07-26  8:19   ` Johannes Berg
  5 siblings, 0 replies; 9+ messages in thread
From: Johannes Berg @ 2013-07-26  8:19 UTC (permalink / raw)
  To: linux-wireless; +Cc: Emmanuel Grumbach

From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>

If we forget to do so, we can't send HCMD to firmware while
the NIC is in RFKILL state.

Cc: stable@vger.kernel.org
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/iwlwifi/iwl-prph.h | 2 ++
 drivers/net/wireless/iwlwifi/pcie/rx.c  | 8 ++++++++
 2 files changed, 10 insertions(+)

diff --git a/drivers/net/wireless/iwlwifi/iwl-prph.h b/drivers/net/wireless/iwlwifi/iwl-prph.h
index ff8cc75..a70c7b9 100644
--- a/drivers/net/wireless/iwlwifi/iwl-prph.h
+++ b/drivers/net/wireless/iwlwifi/iwl-prph.h
@@ -97,6 +97,8 @@
 
 #define APMG_PCIDEV_STT_VAL_L1_ACT_DIS		(0x00000800)
 
+#define APMG_RTC_INT_STT_RFKILL		(0x10000000)
+
 /* Device system time */
 #define DEVICE_SYSTEM_TIME_REG 0xA0206C
 
diff --git a/drivers/net/wireless/iwlwifi/pcie/rx.c b/drivers/net/wireless/iwlwifi/pcie/rx.c
index fd848cd..f600e68 100644
--- a/drivers/net/wireless/iwlwifi/pcie/rx.c
+++ b/drivers/net/wireless/iwlwifi/pcie/rx.c
@@ -888,6 +888,14 @@ irqreturn_t iwl_pcie_irq_handler(int irq, void *dev_id)
 
 		iwl_op_mode_hw_rf_kill(trans->op_mode, hw_rfkill);
 		if (hw_rfkill) {
+			/*
+			 * Clear the interrupt in APMG if the NIC is going down.
+			 * Note that when the NIC exits RFkill (else branch), we
+			 * can't access prph and the NIC will be reset in
+			 * start_hw anyway.
+			 */
+			iwl_write_prph(trans, APMG_RTC_INT_STT_REG,
+				       APMG_RTC_INT_STT_RFKILL);
 			set_bit(STATUS_RFKILL, &trans_pcie->status);
 			if (test_and_clear_bit(STATUS_HCMD_ACTIVE,
 					       &trans_pcie->status))
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: pull-request: iwlwifi-fixes 2013-07-26
  2013-07-26  8:17 pull-request: iwlwifi-fixes 2013-07-26 Johannes Berg
  2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
@ 2013-07-29 18:45 ` John W. Linville
  1 sibling, 0 replies; 9+ messages in thread
From: John W. Linville @ 2013-07-29 18:45 UTC (permalink / raw)
  To: Johannes Berg; +Cc: linux-wireless

On Fri, Jul 26, 2013 at 10:17:55AM +0200, Johannes Berg wrote:
> John,
> 
> Yet some more fixes - we're adding tests and are doing a debug cycle
> with them.
> 
> We have a scan fix for passive channels, a new PCI device ID for an old
> device, a NIC reset fix, an RF-Kill fix, a fix for powersave when GO
> interfaces are present as well as an aggregation session fix (for a
> corner case) and a workaround for a firmware design issue - it only
> supports a single GTK in D3.
> 
> Let me know if there's any problem.
> 
> johannes
> 
> 
> 
> The following changes since commit a590ad411891de551e6de1b51ea635c0484148d6:
> 
>   iwlwifi: mvm: remove extra SSID from probe request (2013-07-16 13:55:15 +0300)
> 
> are available in the git repository at:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-fixes.git for-john
> 
> for you to fetch changes up to a53ee0a308b16e392e0219c585b10f329345766b:
> 
>   iwlwifi: pcie: clear RFKILL interrupt in AMPG (2013-07-26 10:07:10 +0200)

Pulling now...

-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2013-07-29 19:00 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-26  8:17 pull-request: iwlwifi-fixes 2013-07-26 Johannes Berg
2013-07-26  8:19 ` [PATCH 1/7] iwlwifi: add DELL SKU for 5150 HMC Johannes Berg
2013-07-26  8:19   ` [PATCH 2/7] iwlwifi: mvm: use only a single GTK in D3 Johannes Berg
2013-07-26  8:19   ` [PATCH 3/7] iwlwifi: mvm: set SSID bits for passive channels Johannes Berg
2013-07-26  8:19   ` [PATCH 4/7] iwlwifi: pcie: reset the NIC before the bring up Johannes Berg
2013-07-26  8:19   ` [PATCH 5/7] iwlwifi: mvm: Disable managed PS when GO is added Johannes Berg
2013-07-26  8:19   ` [PATCH 6/7] iwlwifi: mvm: fix flushing not started aggregation sessions Johannes Berg
2013-07-26  8:19   ` [PATCH 7/7] iwlwifi: pcie: clear RFKILL interrupt in AMPG Johannes Berg
2013-07-29 18:45 ` pull-request: iwlwifi-fixes 2013-07-26 John W. Linville

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.