aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2013-10-09 14:04:00 -0400
committerDavid S. Miller <davem@davemloft.net>2013-10-09 14:04:00 -0400
commit87b0a0b5c46aea63cdc5c5d788fe2c91406e3161 (patch)
treea33ee42c56bfaf4de51eb5522f3af9de428e10ba /drivers/net
parent9ed8111d021696e1f8ae3115a8a33bc6d34e6062 (diff)
parentb26082b9945a9aca85d51be37824f852617c7129 (diff)
Merge branch 'for-davem' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless
John W. Linville says: =================== Please pull this batch of fixes intended for 3.12... Most of the bits are for iwlwifi -- Johannes says: "I have a fix for WoWLAN/D3, a PCIe device fix, we're removing a warning, there's a fix for RF-kill while scanning (which goes together with a mac80211 fix) and last but not least we have many new PCI IDs." Also for iwlwifi is a patch from Johannes to correct some merge damage that crept into the tree before the last merge window. On top of that, Felix Fietkau sends an ath9k patch to avoid a Tx scheduling hang when changing channels to do a scan. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/wireless/ath/ath9k/main.c23
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-6000.c6
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-config.h1
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-trans.h6
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/power.c5
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/scan.c12
-rw-r--r--drivers/net/wireless/iwlwifi/pcie/drv.c42
-rw-r--r--drivers/net/wireless/iwlwifi/pcie/trans.c8
-rw-r--r--drivers/net/wireless/iwlwifi/pcie/tx.c2
9 files changed, 85 insertions, 20 deletions
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c
index e4f65900132d..709301f88dcd 100644
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
@@ -208,6 +208,7 @@ static bool ath_complete_reset(struct ath_softc *sc, bool start)
208 struct ath_hw *ah = sc->sc_ah; 208 struct ath_hw *ah = sc->sc_ah;
209 struct ath_common *common = ath9k_hw_common(ah); 209 struct ath_common *common = ath9k_hw_common(ah);
210 unsigned long flags; 210 unsigned long flags;
211 int i;
211 212
212 if (ath_startrecv(sc) != 0) { 213 if (ath_startrecv(sc) != 0) {
213 ath_err(common, "Unable to restart recv logic\n"); 214 ath_err(common, "Unable to restart recv logic\n");
@@ -235,6 +236,15 @@ static bool ath_complete_reset(struct ath_softc *sc, bool start)
235 } 236 }
236 work: 237 work:
237 ath_restart_work(sc); 238 ath_restart_work(sc);
239
240 for (i = 0; i < ATH9K_NUM_TX_QUEUES; i++) {
241 if (!ATH_TXQ_SETUP(sc, i))
242 continue;
243
244 spin_lock_bh(&sc->tx.txq[i].axq_lock);
245 ath_txq_schedule(sc, &sc->tx.txq[i]);
246 spin_unlock_bh(&sc->tx.txq[i].axq_lock);
247 }
238 } 248 }
239 249
240 ieee80211_wake_queues(sc->hw); 250 ieee80211_wake_queues(sc->hw);
@@ -539,21 +549,10 @@ chip_reset:
539 549
540static int ath_reset(struct ath_softc *sc) 550static int ath_reset(struct ath_softc *sc)
541{ 551{
542 int i, r; 552 int r;
543 553
544 ath9k_ps_wakeup(sc); 554 ath9k_ps_wakeup(sc);
545
546 r = ath_reset_internal(sc, NULL); 555 r = ath_reset_internal(sc, NULL);
547
548 for (i = 0; i < ATH9K_NUM_TX_QUEUES; i++) {
549 if (!ATH_TXQ_SETUP(sc, i))
550 continue;
551
552 spin_lock_bh(&sc->tx.txq[i].axq_lock);
553 ath_txq_schedule(sc, &sc->tx.txq[i]);
554 spin_unlock_bh(&sc->tx.txq[i].axq_lock);
555 }
556
557 ath9k_ps_restore(sc); 556 ath9k_ps_restore(sc);
558 557
559 return r; 558 return r;
diff --git a/drivers/net/wireless/iwlwifi/iwl-6000.c b/drivers/net/wireless/iwlwifi/iwl-6000.c
index 30d45e2fc193..8ac305be68f4 100644
--- a/drivers/net/wireless/iwlwifi/iwl-6000.c
+++ b/drivers/net/wireless/iwlwifi/iwl-6000.c
@@ -240,6 +240,12 @@ const struct iwl_cfg iwl6035_2agn_cfg = {
240 .ht_params = &iwl6000_ht_params, 240 .ht_params = &iwl6000_ht_params,
241}; 241};
242 242
243const struct iwl_cfg iwl6035_2agn_sff_cfg = {
244 .name = "Intel(R) Centrino(R) Ultimate-N 6235 AGN",
245 IWL_DEVICE_6035,
246 .ht_params = &iwl6000_ht_params,
247};
248
243const struct iwl_cfg iwl1030_bgn_cfg = { 249const struct iwl_cfg iwl1030_bgn_cfg = {
244 .name = "Intel(R) Centrino(R) Wireless-N 1030 BGN", 250 .name = "Intel(R) Centrino(R) Wireless-N 1030 BGN",
245 IWL_DEVICE_6030, 251 IWL_DEVICE_6030,
diff --git a/drivers/net/wireless/iwlwifi/iwl-config.h b/drivers/net/wireless/iwlwifi/iwl-config.h
index e4d370bff306..b03c25e14903 100644
--- a/drivers/net/wireless/iwlwifi/iwl-config.h
+++ b/drivers/net/wireless/iwlwifi/iwl-config.h
@@ -280,6 +280,7 @@ extern const struct iwl_cfg iwl2000_2bgn_cfg;
280extern const struct iwl_cfg iwl2000_2bgn_d_cfg; 280extern const struct iwl_cfg iwl2000_2bgn_d_cfg;
281extern const struct iwl_cfg iwl2030_2bgn_cfg; 281extern const struct iwl_cfg iwl2030_2bgn_cfg;
282extern const struct iwl_cfg iwl6035_2agn_cfg; 282extern const struct iwl_cfg iwl6035_2agn_cfg;
283extern const struct iwl_cfg iwl6035_2agn_sff_cfg;
283extern const struct iwl_cfg iwl105_bgn_cfg; 284extern const struct iwl_cfg iwl105_bgn_cfg;
284extern const struct iwl_cfg iwl105_bgn_d_cfg; 285extern const struct iwl_cfg iwl105_bgn_d_cfg;
285extern const struct iwl_cfg iwl135_bgn_cfg; 286extern const struct iwl_cfg iwl135_bgn_cfg;
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans.h b/drivers/net/wireless/iwlwifi/iwl-trans.h
index dd57a36ecb10..80b47508647c 100644
--- a/drivers/net/wireless/iwlwifi/iwl-trans.h
+++ b/drivers/net/wireless/iwlwifi/iwl-trans.h
@@ -601,8 +601,10 @@ static inline int iwl_trans_send_cmd(struct iwl_trans *trans,
601{ 601{
602 int ret; 602 int ret;
603 603
604 WARN_ONCE(trans->state != IWL_TRANS_FW_ALIVE, 604 if (trans->state != IWL_TRANS_FW_ALIVE) {
605 "%s bad state = %d", __func__, trans->state); 605 IWL_ERR(trans, "%s bad state = %d", __func__, trans->state);
606 return -EIO;
607 }
606 608
607 if (!(cmd->flags & CMD_ASYNC)) 609 if (!(cmd->flags & CMD_ASYNC))
608 lock_map_acquire_read(&trans->sync_cmd_lockdep_map); 610 lock_map_acquire_read(&trans->sync_cmd_lockdep_map);
diff --git a/drivers/net/wireless/iwlwifi/mvm/power.c b/drivers/net/wireless/iwlwifi/mvm/power.c
index 21407a353a3b..d58e393324ef 100644
--- a/drivers/net/wireless/iwlwifi/mvm/power.c
+++ b/drivers/net/wireless/iwlwifi/mvm/power.c
@@ -273,7 +273,10 @@ static void iwl_mvm_power_build_cmd(struct iwl_mvm *mvm,
273 if (!mvmvif->queue_params[ac].uapsd) 273 if (!mvmvif->queue_params[ac].uapsd)
274 continue; 274 continue;
275 275
276 cmd->flags |= cpu_to_le16(POWER_FLAGS_ADVANCE_PM_ENA_MSK); 276 if (mvm->cur_ucode != IWL_UCODE_WOWLAN)
277 cmd->flags |=
278 cpu_to_le16(POWER_FLAGS_ADVANCE_PM_ENA_MSK);
279
277 cmd->uapsd_ac_flags |= BIT(ac); 280 cmd->uapsd_ac_flags |= BIT(ac);
278 281
279 /* QNDP TID - the highest TID with no admission control */ 282 /* QNDP TID - the highest TID with no admission control */
diff --git a/drivers/net/wireless/iwlwifi/mvm/scan.c b/drivers/net/wireless/iwlwifi/mvm/scan.c
index 9a7ab8495300..621fb71f282a 100644
--- a/drivers/net/wireless/iwlwifi/mvm/scan.c
+++ b/drivers/net/wireless/iwlwifi/mvm/scan.c
@@ -394,6 +394,11 @@ static bool iwl_mvm_scan_abort_notif(struct iwl_notif_wait_data *notif_wait,
394 return false; 394 return false;
395 } 395 }
396 396
397 /*
398 * If scan cannot be aborted, it means that we had a
399 * SCAN_COMPLETE_NOTIFICATION in the pipe and it called
400 * ieee80211_scan_completed already.
401 */
397 IWL_DEBUG_SCAN(mvm, "Scan cannot be aborted, exit now: %d\n", 402 IWL_DEBUG_SCAN(mvm, "Scan cannot be aborted, exit now: %d\n",
398 *resp); 403 *resp);
399 return true; 404 return true;
@@ -417,14 +422,19 @@ void iwl_mvm_cancel_scan(struct iwl_mvm *mvm)
417 SCAN_COMPLETE_NOTIFICATION }; 422 SCAN_COMPLETE_NOTIFICATION };
418 int ret; 423 int ret;
419 424
425 if (mvm->scan_status == IWL_MVM_SCAN_NONE)
426 return;
427
420 iwl_init_notification_wait(&mvm->notif_wait, &wait_scan_abort, 428 iwl_init_notification_wait(&mvm->notif_wait, &wait_scan_abort,
421 scan_abort_notif, 429 scan_abort_notif,
422 ARRAY_SIZE(scan_abort_notif), 430 ARRAY_SIZE(scan_abort_notif),
423 iwl_mvm_scan_abort_notif, NULL); 431 iwl_mvm_scan_abort_notif, NULL);
424 432
425 ret = iwl_mvm_send_cmd_pdu(mvm, SCAN_ABORT_CMD, CMD_SYNC, 0, NULL); 433 ret = iwl_mvm_send_cmd_pdu(mvm, SCAN_ABORT_CMD,
434 CMD_SYNC | CMD_SEND_IN_RFKILL, 0, NULL);
426 if (ret) { 435 if (ret) {
427 IWL_ERR(mvm, "Couldn't send SCAN_ABORT_CMD: %d\n", ret); 436 IWL_ERR(mvm, "Couldn't send SCAN_ABORT_CMD: %d\n", ret);
437 /* mac80211's state will be cleaned in the fw_restart flow */
428 goto out_remove_notif; 438 goto out_remove_notif;
429 } 439 }
430 440
diff --git a/drivers/net/wireless/iwlwifi/pcie/drv.c b/drivers/net/wireless/iwlwifi/pcie/drv.c
index dc02cb9792af..26108a1a29fa 100644
--- a/drivers/net/wireless/iwlwifi/pcie/drv.c
+++ b/drivers/net/wireless/iwlwifi/pcie/drv.c
@@ -139,13 +139,16 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = {
139 139
140/* 6x00 Series */ 140/* 6x00 Series */
141 {IWL_PCI_DEVICE(0x422B, 0x1101, iwl6000_3agn_cfg)}, 141 {IWL_PCI_DEVICE(0x422B, 0x1101, iwl6000_3agn_cfg)},
142 {IWL_PCI_DEVICE(0x422B, 0x1108, iwl6000_3agn_cfg)},
142 {IWL_PCI_DEVICE(0x422B, 0x1121, iwl6000_3agn_cfg)}, 143 {IWL_PCI_DEVICE(0x422B, 0x1121, iwl6000_3agn_cfg)},
144 {IWL_PCI_DEVICE(0x422B, 0x1128, iwl6000_3agn_cfg)},
143 {IWL_PCI_DEVICE(0x422C, 0x1301, iwl6000i_2agn_cfg)}, 145 {IWL_PCI_DEVICE(0x422C, 0x1301, iwl6000i_2agn_cfg)},
144 {IWL_PCI_DEVICE(0x422C, 0x1306, iwl6000i_2abg_cfg)}, 146 {IWL_PCI_DEVICE(0x422C, 0x1306, iwl6000i_2abg_cfg)},
145 {IWL_PCI_DEVICE(0x422C, 0x1307, iwl6000i_2bg_cfg)}, 147 {IWL_PCI_DEVICE(0x422C, 0x1307, iwl6000i_2bg_cfg)},
146 {IWL_PCI_DEVICE(0x422C, 0x1321, iwl6000i_2agn_cfg)}, 148 {IWL_PCI_DEVICE(0x422C, 0x1321, iwl6000i_2agn_cfg)},
147 {IWL_PCI_DEVICE(0x422C, 0x1326, iwl6000i_2abg_cfg)}, 149 {IWL_PCI_DEVICE(0x422C, 0x1326, iwl6000i_2abg_cfg)},
148 {IWL_PCI_DEVICE(0x4238, 0x1111, iwl6000_3agn_cfg)}, 150 {IWL_PCI_DEVICE(0x4238, 0x1111, iwl6000_3agn_cfg)},
151 {IWL_PCI_DEVICE(0x4238, 0x1118, iwl6000_3agn_cfg)},
149 {IWL_PCI_DEVICE(0x4239, 0x1311, iwl6000i_2agn_cfg)}, 152 {IWL_PCI_DEVICE(0x4239, 0x1311, iwl6000i_2agn_cfg)},
150 {IWL_PCI_DEVICE(0x4239, 0x1316, iwl6000i_2abg_cfg)}, 153 {IWL_PCI_DEVICE(0x4239, 0x1316, iwl6000i_2abg_cfg)},
151 154
@@ -153,12 +156,16 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = {
153 {IWL_PCI_DEVICE(0x0082, 0x1301, iwl6005_2agn_cfg)}, 156 {IWL_PCI_DEVICE(0x0082, 0x1301, iwl6005_2agn_cfg)},
154 {IWL_PCI_DEVICE(0x0082, 0x1306, iwl6005_2abg_cfg)}, 157 {IWL_PCI_DEVICE(0x0082, 0x1306, iwl6005_2abg_cfg)},
155 {IWL_PCI_DEVICE(0x0082, 0x1307, iwl6005_2bg_cfg)}, 158 {IWL_PCI_DEVICE(0x0082, 0x1307, iwl6005_2bg_cfg)},
159 {IWL_PCI_DEVICE(0x0082, 0x1308, iwl6005_2agn_cfg)},
156 {IWL_PCI_DEVICE(0x0082, 0x1321, iwl6005_2agn_cfg)}, 160 {IWL_PCI_DEVICE(0x0082, 0x1321, iwl6005_2agn_cfg)},
157 {IWL_PCI_DEVICE(0x0082, 0x1326, iwl6005_2abg_cfg)}, 161 {IWL_PCI_DEVICE(0x0082, 0x1326, iwl6005_2abg_cfg)},
162 {IWL_PCI_DEVICE(0x0082, 0x1328, iwl6005_2agn_cfg)},
158 {IWL_PCI_DEVICE(0x0085, 0x1311, iwl6005_2agn_cfg)}, 163 {IWL_PCI_DEVICE(0x0085, 0x1311, iwl6005_2agn_cfg)},
164 {IWL_PCI_DEVICE(0x0085, 0x1318, iwl6005_2agn_cfg)},
159 {IWL_PCI_DEVICE(0x0085, 0x1316, iwl6005_2abg_cfg)}, 165 {IWL_PCI_DEVICE(0x0085, 0x1316, iwl6005_2abg_cfg)},
160 {IWL_PCI_DEVICE(0x0082, 0xC020, iwl6005_2agn_sff_cfg)}, 166 {IWL_PCI_DEVICE(0x0082, 0xC020, iwl6005_2agn_sff_cfg)},
161 {IWL_PCI_DEVICE(0x0085, 0xC220, iwl6005_2agn_sff_cfg)}, 167 {IWL_PCI_DEVICE(0x0085, 0xC220, iwl6005_2agn_sff_cfg)},
168 {IWL_PCI_DEVICE(0x0085, 0xC228, iwl6005_2agn_sff_cfg)},
162 {IWL_PCI_DEVICE(0x0082, 0x4820, iwl6005_2agn_d_cfg)}, 169 {IWL_PCI_DEVICE(0x0082, 0x4820, iwl6005_2agn_d_cfg)},
163 {IWL_PCI_DEVICE(0x0082, 0x1304, iwl6005_2agn_mow1_cfg)},/* low 5GHz active */ 170 {IWL_PCI_DEVICE(0x0082, 0x1304, iwl6005_2agn_mow1_cfg)},/* low 5GHz active */
164 {IWL_PCI_DEVICE(0x0082, 0x1305, iwl6005_2agn_mow2_cfg)},/* high 5GHz active */ 171 {IWL_PCI_DEVICE(0x0082, 0x1305, iwl6005_2agn_mow2_cfg)},/* high 5GHz active */
@@ -240,8 +247,11 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = {
240 247
241/* 6x35 Series */ 248/* 6x35 Series */
242 {IWL_PCI_DEVICE(0x088E, 0x4060, iwl6035_2agn_cfg)}, 249 {IWL_PCI_DEVICE(0x088E, 0x4060, iwl6035_2agn_cfg)},
250 {IWL_PCI_DEVICE(0x088E, 0x406A, iwl6035_2agn_sff_cfg)},
243 {IWL_PCI_DEVICE(0x088F, 0x4260, iwl6035_2agn_cfg)}, 251 {IWL_PCI_DEVICE(0x088F, 0x4260, iwl6035_2agn_cfg)},
252 {IWL_PCI_DEVICE(0x088F, 0x426A, iwl6035_2agn_sff_cfg)},
244 {IWL_PCI_DEVICE(0x088E, 0x4460, iwl6035_2agn_cfg)}, 253 {IWL_PCI_DEVICE(0x088E, 0x4460, iwl6035_2agn_cfg)},
254 {IWL_PCI_DEVICE(0x088E, 0x446A, iwl6035_2agn_sff_cfg)},
245 {IWL_PCI_DEVICE(0x088E, 0x4860, iwl6035_2agn_cfg)}, 255 {IWL_PCI_DEVICE(0x088E, 0x4860, iwl6035_2agn_cfg)},
246 {IWL_PCI_DEVICE(0x088F, 0x5260, iwl6035_2agn_cfg)}, 256 {IWL_PCI_DEVICE(0x088F, 0x5260, iwl6035_2agn_cfg)},
247 257
@@ -260,54 +270,86 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = {
260#if IS_ENABLED(CONFIG_IWLMVM) 270#if IS_ENABLED(CONFIG_IWLMVM)
261/* 7000 Series */ 271/* 7000 Series */
262 {IWL_PCI_DEVICE(0x08B1, 0x4070, iwl7260_2ac_cfg)}, 272 {IWL_PCI_DEVICE(0x08B1, 0x4070, iwl7260_2ac_cfg)},
273 {IWL_PCI_DEVICE(0x08B1, 0x4072, iwl7260_2ac_cfg)},
263 {IWL_PCI_DEVICE(0x08B1, 0x4170, iwl7260_2ac_cfg)}, 274 {IWL_PCI_DEVICE(0x08B1, 0x4170, iwl7260_2ac_cfg)},
264 {IWL_PCI_DEVICE(0x08B1, 0x4060, iwl7260_2n_cfg)}, 275 {IWL_PCI_DEVICE(0x08B1, 0x4060, iwl7260_2n_cfg)},
276 {IWL_PCI_DEVICE(0x08B1, 0x406A, iwl7260_2n_cfg)},
265 {IWL_PCI_DEVICE(0x08B1, 0x4160, iwl7260_2n_cfg)}, 277 {IWL_PCI_DEVICE(0x08B1, 0x4160, iwl7260_2n_cfg)},
266 {IWL_PCI_DEVICE(0x08B1, 0x4062, iwl7260_n_cfg)}, 278 {IWL_PCI_DEVICE(0x08B1, 0x4062, iwl7260_n_cfg)},
267 {IWL_PCI_DEVICE(0x08B1, 0x4162, iwl7260_n_cfg)}, 279 {IWL_PCI_DEVICE(0x08B1, 0x4162, iwl7260_n_cfg)},
268 {IWL_PCI_DEVICE(0x08B2, 0x4270, iwl7260_2ac_cfg)}, 280 {IWL_PCI_DEVICE(0x08B2, 0x4270, iwl7260_2ac_cfg)},
281 {IWL_PCI_DEVICE(0x08B2, 0x4272, iwl7260_2ac_cfg)},
269 {IWL_PCI_DEVICE(0x08B2, 0x4260, iwl7260_2n_cfg)}, 282 {IWL_PCI_DEVICE(0x08B2, 0x4260, iwl7260_2n_cfg)},
283 {IWL_PCI_DEVICE(0x08B2, 0x426A, iwl7260_2n_cfg)},
270 {IWL_PCI_DEVICE(0x08B2, 0x4262, iwl7260_n_cfg)}, 284 {IWL_PCI_DEVICE(0x08B2, 0x4262, iwl7260_n_cfg)},
271 {IWL_PCI_DEVICE(0x08B1, 0x4470, iwl7260_2ac_cfg)}, 285 {IWL_PCI_DEVICE(0x08B1, 0x4470, iwl7260_2ac_cfg)},
286 {IWL_PCI_DEVICE(0x08B1, 0x4472, iwl7260_2ac_cfg)},
272 {IWL_PCI_DEVICE(0x08B1, 0x4460, iwl7260_2n_cfg)}, 287 {IWL_PCI_DEVICE(0x08B1, 0x4460, iwl7260_2n_cfg)},
288 {IWL_PCI_DEVICE(0x08B1, 0x446A, iwl7260_2n_cfg)},
273 {IWL_PCI_DEVICE(0x08B1, 0x4462, iwl7260_n_cfg)}, 289 {IWL_PCI_DEVICE(0x08B1, 0x4462, iwl7260_n_cfg)},
274 {IWL_PCI_DEVICE(0x08B1, 0x4870, iwl7260_2ac_cfg)}, 290 {IWL_PCI_DEVICE(0x08B1, 0x4870, iwl7260_2ac_cfg)},
275 {IWL_PCI_DEVICE(0x08B1, 0x486E, iwl7260_2ac_cfg)}, 291 {IWL_PCI_DEVICE(0x08B1, 0x486E, iwl7260_2ac_cfg)},
276 {IWL_PCI_DEVICE(0x08B1, 0x4A70, iwl7260_2ac_cfg_high_temp)}, 292 {IWL_PCI_DEVICE(0x08B1, 0x4A70, iwl7260_2ac_cfg_high_temp)},
277 {IWL_PCI_DEVICE(0x08B1, 0x4A6E, iwl7260_2ac_cfg_high_temp)}, 293 {IWL_PCI_DEVICE(0x08B1, 0x4A6E, iwl7260_2ac_cfg_high_temp)},
278 {IWL_PCI_DEVICE(0x08B1, 0x4A6C, iwl7260_2ac_cfg_high_temp)}, 294 {IWL_PCI_DEVICE(0x08B1, 0x4A6C, iwl7260_2ac_cfg_high_temp)},
295 {IWL_PCI_DEVICE(0x08B1, 0x4570, iwl7260_2ac_cfg)},
296 {IWL_PCI_DEVICE(0x08B1, 0x4560, iwl7260_2n_cfg)},
297 {IWL_PCI_DEVICE(0x08B2, 0x4370, iwl7260_2ac_cfg)},
298 {IWL_PCI_DEVICE(0x08B2, 0x4360, iwl7260_2n_cfg)},
299 {IWL_PCI_DEVICE(0x08B1, 0x5070, iwl7260_2ac_cfg)},
279 {IWL_PCI_DEVICE(0x08B1, 0x4020, iwl7260_2n_cfg)}, 300 {IWL_PCI_DEVICE(0x08B1, 0x4020, iwl7260_2n_cfg)},
301 {IWL_PCI_DEVICE(0x08B1, 0x402A, iwl7260_2n_cfg)},
280 {IWL_PCI_DEVICE(0x08B2, 0x4220, iwl7260_2n_cfg)}, 302 {IWL_PCI_DEVICE(0x08B2, 0x4220, iwl7260_2n_cfg)},
281 {IWL_PCI_DEVICE(0x08B1, 0x4420, iwl7260_2n_cfg)}, 303 {IWL_PCI_DEVICE(0x08B1, 0x4420, iwl7260_2n_cfg)},
282 {IWL_PCI_DEVICE(0x08B1, 0xC070, iwl7260_2ac_cfg)}, 304 {IWL_PCI_DEVICE(0x08B1, 0xC070, iwl7260_2ac_cfg)},
305 {IWL_PCI_DEVICE(0x08B1, 0xC072, iwl7260_2ac_cfg)},
283 {IWL_PCI_DEVICE(0x08B1, 0xC170, iwl7260_2ac_cfg)}, 306 {IWL_PCI_DEVICE(0x08B1, 0xC170, iwl7260_2ac_cfg)},
284 {IWL_PCI_DEVICE(0x08B1, 0xC060, iwl7260_2n_cfg)}, 307 {IWL_PCI_DEVICE(0x08B1, 0xC060, iwl7260_2n_cfg)},
308 {IWL_PCI_DEVICE(0x08B1, 0xC06A, iwl7260_2n_cfg)},
285 {IWL_PCI_DEVICE(0x08B1, 0xC160, iwl7260_2n_cfg)}, 309 {IWL_PCI_DEVICE(0x08B1, 0xC160, iwl7260_2n_cfg)},
286 {IWL_PCI_DEVICE(0x08B1, 0xC062, iwl7260_n_cfg)}, 310 {IWL_PCI_DEVICE(0x08B1, 0xC062, iwl7260_n_cfg)},
287 {IWL_PCI_DEVICE(0x08B1, 0xC162, iwl7260_n_cfg)}, 311 {IWL_PCI_DEVICE(0x08B1, 0xC162, iwl7260_n_cfg)},
312 {IWL_PCI_DEVICE(0x08B1, 0xC770, iwl7260_2ac_cfg)},
313 {IWL_PCI_DEVICE(0x08B1, 0xC760, iwl7260_2n_cfg)},
288 {IWL_PCI_DEVICE(0x08B2, 0xC270, iwl7260_2ac_cfg)}, 314 {IWL_PCI_DEVICE(0x08B2, 0xC270, iwl7260_2ac_cfg)},
315 {IWL_PCI_DEVICE(0x08B2, 0xC272, iwl7260_2ac_cfg)},
289 {IWL_PCI_DEVICE(0x08B2, 0xC260, iwl7260_2n_cfg)}, 316 {IWL_PCI_DEVICE(0x08B2, 0xC260, iwl7260_2n_cfg)},
317 {IWL_PCI_DEVICE(0x08B2, 0xC26A, iwl7260_n_cfg)},
290 {IWL_PCI_DEVICE(0x08B2, 0xC262, iwl7260_n_cfg)}, 318 {IWL_PCI_DEVICE(0x08B2, 0xC262, iwl7260_n_cfg)},
291 {IWL_PCI_DEVICE(0x08B1, 0xC470, iwl7260_2ac_cfg)}, 319 {IWL_PCI_DEVICE(0x08B1, 0xC470, iwl7260_2ac_cfg)},
320 {IWL_PCI_DEVICE(0x08B1, 0xC472, iwl7260_2ac_cfg)},
292 {IWL_PCI_DEVICE(0x08B1, 0xC460, iwl7260_2n_cfg)}, 321 {IWL_PCI_DEVICE(0x08B1, 0xC460, iwl7260_2n_cfg)},
293 {IWL_PCI_DEVICE(0x08B1, 0xC462, iwl7260_n_cfg)}, 322 {IWL_PCI_DEVICE(0x08B1, 0xC462, iwl7260_n_cfg)},
323 {IWL_PCI_DEVICE(0x08B1, 0xC570, iwl7260_2ac_cfg)},
324 {IWL_PCI_DEVICE(0x08B1, 0xC560, iwl7260_2n_cfg)},
325 {IWL_PCI_DEVICE(0x08B2, 0xC370, iwl7260_2ac_cfg)},
326 {IWL_PCI_DEVICE(0x08B1, 0xC360, iwl7260_2n_cfg)},
294 {IWL_PCI_DEVICE(0x08B1, 0xC020, iwl7260_2n_cfg)}, 327 {IWL_PCI_DEVICE(0x08B1, 0xC020, iwl7260_2n_cfg)},
328 {IWL_PCI_DEVICE(0x08B1, 0xC02A, iwl7260_2n_cfg)},
295 {IWL_PCI_DEVICE(0x08B2, 0xC220, iwl7260_2n_cfg)}, 329 {IWL_PCI_DEVICE(0x08B2, 0xC220, iwl7260_2n_cfg)},
296 {IWL_PCI_DEVICE(0x08B1, 0xC420, iwl7260_2n_cfg)}, 330 {IWL_PCI_DEVICE(0x08B1, 0xC420, iwl7260_2n_cfg)},
297 331
298/* 3160 Series */ 332/* 3160 Series */
299 {IWL_PCI_DEVICE(0x08B3, 0x0070, iwl3160_2ac_cfg)}, 333 {IWL_PCI_DEVICE(0x08B3, 0x0070, iwl3160_2ac_cfg)},
334 {IWL_PCI_DEVICE(0x08B3, 0x0072, iwl3160_2ac_cfg)},
300 {IWL_PCI_DEVICE(0x08B3, 0x0170, iwl3160_2ac_cfg)}, 335 {IWL_PCI_DEVICE(0x08B3, 0x0170, iwl3160_2ac_cfg)},
336 {IWL_PCI_DEVICE(0x08B3, 0x0172, iwl3160_2ac_cfg)},
301 {IWL_PCI_DEVICE(0x08B3, 0x0060, iwl3160_2n_cfg)}, 337 {IWL_PCI_DEVICE(0x08B3, 0x0060, iwl3160_2n_cfg)},
302 {IWL_PCI_DEVICE(0x08B3, 0x0062, iwl3160_n_cfg)}, 338 {IWL_PCI_DEVICE(0x08B3, 0x0062, iwl3160_n_cfg)},
303 {IWL_PCI_DEVICE(0x08B4, 0x0270, iwl3160_2ac_cfg)}, 339 {IWL_PCI_DEVICE(0x08B4, 0x0270, iwl3160_2ac_cfg)},
340 {IWL_PCI_DEVICE(0x08B4, 0x0272, iwl3160_2ac_cfg)},
304 {IWL_PCI_DEVICE(0x08B3, 0x0470, iwl3160_2ac_cfg)}, 341 {IWL_PCI_DEVICE(0x08B3, 0x0470, iwl3160_2ac_cfg)},
342 {IWL_PCI_DEVICE(0x08B3, 0x0472, iwl3160_2ac_cfg)},
343 {IWL_PCI_DEVICE(0x08B4, 0x0370, iwl3160_2ac_cfg)},
305 {IWL_PCI_DEVICE(0x08B3, 0x8070, iwl3160_2ac_cfg)}, 344 {IWL_PCI_DEVICE(0x08B3, 0x8070, iwl3160_2ac_cfg)},
345 {IWL_PCI_DEVICE(0x08B3, 0x8072, iwl3160_2ac_cfg)},
306 {IWL_PCI_DEVICE(0x08B3, 0x8170, iwl3160_2ac_cfg)}, 346 {IWL_PCI_DEVICE(0x08B3, 0x8170, iwl3160_2ac_cfg)},
347 {IWL_PCI_DEVICE(0x08B3, 0x8172, iwl3160_2ac_cfg)},
307 {IWL_PCI_DEVICE(0x08B3, 0x8060, iwl3160_2n_cfg)}, 348 {IWL_PCI_DEVICE(0x08B3, 0x8060, iwl3160_2n_cfg)},
308 {IWL_PCI_DEVICE(0x08B3, 0x8062, iwl3160_n_cfg)}, 349 {IWL_PCI_DEVICE(0x08B3, 0x8062, iwl3160_n_cfg)},
309 {IWL_PCI_DEVICE(0x08B4, 0x8270, iwl3160_2ac_cfg)}, 350 {IWL_PCI_DEVICE(0x08B4, 0x8270, iwl3160_2ac_cfg)},
310 {IWL_PCI_DEVICE(0x08B3, 0x8470, iwl3160_2ac_cfg)}, 351 {IWL_PCI_DEVICE(0x08B3, 0x8470, iwl3160_2ac_cfg)},
352 {IWL_PCI_DEVICE(0x08B3, 0x8570, iwl3160_2ac_cfg)},
311#endif /* CONFIG_IWLMVM */ 353#endif /* CONFIG_IWLMVM */
312 354
313 {0} 355 {0}
diff --git a/drivers/net/wireless/iwlwifi/pcie/trans.c b/drivers/net/wireless/iwlwifi/pcie/trans.c
index bad95d28d50d..c3f904d422b0 100644
--- a/drivers/net/wireless/iwlwifi/pcie/trans.c
+++ b/drivers/net/wireless/iwlwifi/pcie/trans.c
@@ -1401,6 +1401,10 @@ struct iwl_trans *iwl_trans_pcie_alloc(struct pci_dev *pdev,
1401 spin_lock_init(&trans_pcie->reg_lock); 1401 spin_lock_init(&trans_pcie->reg_lock);
1402 init_waitqueue_head(&trans_pcie->ucode_write_waitq); 1402 init_waitqueue_head(&trans_pcie->ucode_write_waitq);
1403 1403
1404 err = pci_enable_device(pdev);
1405 if (err)
1406 goto out_no_pci;
1407
1404 if (!cfg->base_params->pcie_l1_allowed) { 1408 if (!cfg->base_params->pcie_l1_allowed) {
1405 /* 1409 /*
1406 * W/A - seems to solve weird behavior. We need to remove this 1410 * W/A - seems to solve weird behavior. We need to remove this
@@ -1412,10 +1416,6 @@ struct iwl_trans *iwl_trans_pcie_alloc(struct pci_dev *pdev,
1412 PCIE_LINK_STATE_CLKPM); 1416 PCIE_LINK_STATE_CLKPM);
1413 } 1417 }
1414 1418
1415 err = pci_enable_device(pdev);
1416 if (err)
1417 goto out_no_pci;
1418
1419 pci_set_master(pdev); 1419 pci_set_master(pdev);
1420 1420
1421 err = pci_set_dma_mask(pdev, DMA_BIT_MASK(36)); 1421 err = pci_set_dma_mask(pdev, DMA_BIT_MASK(36));
diff --git a/drivers/net/wireless/iwlwifi/pcie/tx.c b/drivers/net/wireless/iwlwifi/pcie/tx.c
index f45eb29c2ede..1424335163b9 100644
--- a/drivers/net/wireless/iwlwifi/pcie/tx.c
+++ b/drivers/net/wireless/iwlwifi/pcie/tx.c
@@ -1102,6 +1102,8 @@ void iwl_trans_pcie_txq_enable(struct iwl_trans *trans, int txq_id, int fifo,
1102 * non-AGG queue. 1102 * non-AGG queue.
1103 */ 1103 */
1104 iwl_clear_bits_prph(trans, SCD_AGGR_SEL, BIT(txq_id)); 1104 iwl_clear_bits_prph(trans, SCD_AGGR_SEL, BIT(txq_id));
1105
1106 ssn = trans_pcie->txq[txq_id].q.read_ptr;
1105 } 1107 }
1106 1108
1107 /* Place first TFD at index corresponding to start sequence number. 1109 /* Place first TFD at index corresponding to start sequence number.