diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2011-11-10 09:55:24 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-11-11 12:32:56 -0500 |
commit | 81a3de1ce2929fef2b112c048c50bc52b686f94d (patch) | |
tree | 70391698cbd9525012bb5242b4dbdda119246239 /drivers | |
parent | 0dcf50ca4ebdef5468aa2475de2b87feec5a1e8f (diff) |
iwlwifi: add debug information on queue stop / wake
Users complain that the traffic gets stalled sometimes. This will
allow easier debugging.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-rx.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-rxon.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-tx.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-debug.h | 4 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-trans-pcie-int.h | 35 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-trans-pcie-tx.c | 14 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-trans-pcie.c | 23 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-trans.h | 15 |
8 files changed, 67 insertions, 33 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rx.c b/drivers/net/wireless/iwlwifi/iwl-agn-rx.c index f0d6d9429be7..fdb4c3786114 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-rx.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rx.c | |||
@@ -800,7 +800,8 @@ static void iwlagn_pass_packet_to_mac80211(struct iwl_priv *priv, | |||
800 | ctx->active.bssid_addr)) | 800 | ctx->active.bssid_addr)) |
801 | continue; | 801 | continue; |
802 | ctx->last_tx_rejected = false; | 802 | ctx->last_tx_rejected = false; |
803 | iwl_trans_wake_any_queue(trans(priv), ctx->ctxid); | 803 | iwl_trans_wake_any_queue(trans(priv), ctx->ctxid, |
804 | "channel got active"); | ||
804 | } | 805 | } |
805 | } | 806 | } |
806 | 807 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c b/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c index b73077fc4b2c..8de97f5a1825 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rxon.c | |||
@@ -844,7 +844,8 @@ void iwlagn_bss_info_changed(struct ieee80211_hw *hw, | |||
844 | if (ctx->last_tx_rejected) { | 844 | if (ctx->last_tx_rejected) { |
845 | ctx->last_tx_rejected = false; | 845 | ctx->last_tx_rejected = false; |
846 | iwl_trans_wake_any_queue(trans(priv), | 846 | iwl_trans_wake_any_queue(trans(priv), |
847 | ctx->ctxid); | 847 | ctx->ctxid, |
848 | "Disassoc: flush queue"); | ||
848 | } | 849 | } |
849 | ctx->staging.filter_flags &= ~RXON_FILTER_ASSOC_MSK; | 850 | ctx->staging.filter_flags &= ~RXON_FILTER_ASSOC_MSK; |
850 | 851 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-tx.c b/drivers/net/wireless/iwlwifi/iwl-agn-tx.c index 014b98ab6816..e6a02e09ee18 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-tx.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-tx.c | |||
@@ -813,7 +813,8 @@ int iwlagn_rx_reply_tx(struct iwl_priv *priv, struct iwl_rx_mem_buffer *rxb, | |||
813 | iwl_is_associated_ctx(ctx) && ctx->vif && | 813 | iwl_is_associated_ctx(ctx) && ctx->vif && |
814 | ctx->vif->type == NL80211_IFTYPE_STATION) { | 814 | ctx->vif->type == NL80211_IFTYPE_STATION) { |
815 | ctx->last_tx_rejected = true; | 815 | ctx->last_tx_rejected = true; |
816 | iwl_trans_stop_queue(trans(priv), txq_id); | 816 | iwl_trans_stop_queue(trans(priv), txq_id, |
817 | "Tx on passive channel"); | ||
817 | 818 | ||
818 | IWL_DEBUG_TX_REPLY(priv, | 819 | IWL_DEBUG_TX_REPLY(priv, |
819 | "TXQ %d status %s (0x%08x) " | 820 | "TXQ %d status %s (0x%08x) " |
diff --git a/drivers/net/wireless/iwlwifi/iwl-debug.h b/drivers/net/wireless/iwlwifi/iwl-debug.h index a11e7aaeb14a..40ef97bac1aa 100644 --- a/drivers/net/wireless/iwlwifi/iwl-debug.h +++ b/drivers/net/wireless/iwlwifi/iwl-debug.h | |||
@@ -166,7 +166,7 @@ static inline void iwl_dbgfs_unregister(struct iwl_priv *priv) | |||
166 | #define IWL_DL_11H (1 << 28) | 166 | #define IWL_DL_11H (1 << 28) |
167 | #define IWL_DL_STATS (1 << 29) | 167 | #define IWL_DL_STATS (1 << 29) |
168 | #define IWL_DL_TX_REPLY (1 << 30) | 168 | #define IWL_DL_TX_REPLY (1 << 30) |
169 | #define IWL_DL_UNUSED (1 << 31) | 169 | #define IWL_DL_TX_QUEUES (1 << 31) |
170 | 170 | ||
171 | #define IWL_DEBUG_INFO(p, f, a...) IWL_DEBUG(p, IWL_DL_INFO, f, ## a) | 171 | #define IWL_DEBUG_INFO(p, f, a...) IWL_DEBUG(p, IWL_DL_INFO, f, ## a) |
172 | #define IWL_DEBUG_MAC80211(p, f, a...) IWL_DEBUG(p, IWL_DL_MAC80211, f, ## a) | 172 | #define IWL_DEBUG_MAC80211(p, f, a...) IWL_DEBUG(p, IWL_DL_MAC80211, f, ## a) |
@@ -203,7 +203,7 @@ static inline void iwl_dbgfs_unregister(struct iwl_priv *priv) | |||
203 | #define IWL_DEBUG_TX_REPLY(p, f, a...) IWL_DEBUG(p, IWL_DL_TX_REPLY, f, ## a) | 203 | #define IWL_DEBUG_TX_REPLY(p, f, a...) IWL_DEBUG(p, IWL_DL_TX_REPLY, f, ## a) |
204 | #define IWL_DEBUG_TX_REPLY_LIMIT(p, f, a...) \ | 204 | #define IWL_DEBUG_TX_REPLY_LIMIT(p, f, a...) \ |
205 | IWL_DEBUG_LIMIT(p, IWL_DL_TX_REPLY, f, ## a) | 205 | IWL_DEBUG_LIMIT(p, IWL_DL_TX_REPLY, f, ## a) |
206 | #define IWL_DEBUG_UNUSED(p, f, a...) IWL_DEBUG(p, IWL_DL_UNUSED, f, ## a) | 206 | #define IWL_DEBUG_TX_QUEUES(p, f, a...) IWL_DEBUG(p, IWL_DL_TX_QUEUES, f, ## a) |
207 | #define IWL_DEBUG_RADIO(p, f, a...) IWL_DEBUG(p, IWL_DL_RADIO, f, ## a) | 207 | #define IWL_DEBUG_RADIO(p, f, a...) IWL_DEBUG(p, IWL_DL_RADIO, f, ## a) |
208 | #define IWL_DEBUG_POWER(p, f, a...) IWL_DEBUG(p, IWL_DL_POWER, f, ## a) | 208 | #define IWL_DEBUG_POWER(p, f, a...) IWL_DEBUG(p, IWL_DL_POWER, f, ## a) |
209 | #define IWL_DEBUG_11H(p, f, a...) IWL_DEBUG(p, IWL_DL_11H, f, ## a) | 209 | #define IWL_DEBUG_11H(p, f, a...) IWL_DEBUG(p, IWL_DL_11H, f, ## a) |
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans-pcie-int.h b/drivers/net/wireless/iwlwifi/iwl-trans-pcie-int.h index 2b6756e8b8f9..afaaa2a51b96 100644 --- a/drivers/net/wireless/iwlwifi/iwl-trans-pcie-int.h +++ b/drivers/net/wireless/iwlwifi/iwl-trans-pcie-int.h | |||
@@ -355,7 +355,7 @@ static inline void iwl_set_swq_id(struct iwl_tx_queue *txq, u8 ac, u8 hwq) | |||
355 | } | 355 | } |
356 | 356 | ||
357 | static inline void iwl_wake_queue(struct iwl_trans *trans, | 357 | static inline void iwl_wake_queue(struct iwl_trans *trans, |
358 | struct iwl_tx_queue *txq) | 358 | struct iwl_tx_queue *txq, const char *msg) |
359 | { | 359 | { |
360 | u8 queue = txq->swq_id; | 360 | u8 queue = txq->swq_id; |
361 | u8 ac = queue & 3; | 361 | u8 ac = queue & 3; |
@@ -363,13 +363,22 @@ static inline void iwl_wake_queue(struct iwl_trans *trans, | |||
363 | struct iwl_trans_pcie *trans_pcie = | 363 | struct iwl_trans_pcie *trans_pcie = |
364 | IWL_TRANS_GET_PCIE_TRANS(trans); | 364 | IWL_TRANS_GET_PCIE_TRANS(trans); |
365 | 365 | ||
366 | if (test_and_clear_bit(hwq, trans_pcie->queue_stopped)) | 366 | if (test_and_clear_bit(hwq, trans_pcie->queue_stopped)) { |
367 | if (atomic_dec_return(&trans_pcie->queue_stop_count[ac]) <= 0) | 367 | if (atomic_dec_return(&trans_pcie->queue_stop_count[ac]) <= 0) { |
368 | iwl_wake_sw_queue(priv(trans), ac); | 368 | iwl_wake_sw_queue(priv(trans), ac); |
369 | IWL_DEBUG_TX_QUEUES(trans, "Wake hwq %d ac %d. %s", | ||
370 | hwq, ac, msg); | ||
371 | } else { | ||
372 | IWL_DEBUG_TX_QUEUES(trans, "Don't wake hwq %d ac %d" | ||
373 | " stop count %d. %s", | ||
374 | hwq, ac, atomic_read(&trans_pcie-> | ||
375 | queue_stop_count[ac]), msg); | ||
376 | } | ||
377 | } | ||
369 | } | 378 | } |
370 | 379 | ||
371 | static inline void iwl_stop_queue(struct iwl_trans *trans, | 380 | static inline void iwl_stop_queue(struct iwl_trans *trans, |
372 | struct iwl_tx_queue *txq) | 381 | struct iwl_tx_queue *txq, const char *msg) |
373 | { | 382 | { |
374 | u8 queue = txq->swq_id; | 383 | u8 queue = txq->swq_id; |
375 | u8 ac = queue & 3; | 384 | u8 ac = queue & 3; |
@@ -377,9 +386,23 @@ static inline void iwl_stop_queue(struct iwl_trans *trans, | |||
377 | struct iwl_trans_pcie *trans_pcie = | 386 | struct iwl_trans_pcie *trans_pcie = |
378 | IWL_TRANS_GET_PCIE_TRANS(trans); | 387 | IWL_TRANS_GET_PCIE_TRANS(trans); |
379 | 388 | ||
380 | if (!test_and_set_bit(hwq, trans_pcie->queue_stopped)) | 389 | if (!test_and_set_bit(hwq, trans_pcie->queue_stopped)) { |
381 | if (atomic_inc_return(&trans_pcie->queue_stop_count[ac]) > 0) | 390 | if (atomic_inc_return(&trans_pcie->queue_stop_count[ac]) > 0) { |
382 | iwl_stop_sw_queue(priv(trans), ac); | 391 | iwl_stop_sw_queue(priv(trans), ac); |
392 | IWL_DEBUG_TX_QUEUES(trans, "Stop hwq %d ac %d" | ||
393 | " stop count %d. %s", | ||
394 | hwq, ac, atomic_read(&trans_pcie-> | ||
395 | queue_stop_count[ac]), msg); | ||
396 | } else { | ||
397 | IWL_DEBUG_TX_QUEUES(trans, "Don't stop hwq %d ac %d" | ||
398 | " stop count %d. %s", | ||
399 | hwq, ac, atomic_read(&trans_pcie-> | ||
400 | queue_stop_count[ac]), msg); | ||
401 | } | ||
402 | } else { | ||
403 | IWL_DEBUG_TX_QUEUES(trans, "stop hwq %d, but it is stopped/ %s", | ||
404 | hwq, msg); | ||
405 | } | ||
383 | } | 406 | } |
384 | 407 | ||
385 | #ifdef ieee80211_stop_queue | 408 | #ifdef ieee80211_stop_queue |
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans-pcie-tx.c b/drivers/net/wireless/iwlwifi/iwl-trans-pcie-tx.c index a6d898b52b9f..6dba1515023c 100644 --- a/drivers/net/wireless/iwlwifi/iwl-trans-pcie-tx.c +++ b/drivers/net/wireless/iwlwifi/iwl-trans-pcie-tx.c | |||
@@ -430,7 +430,7 @@ void iwl_trans_tx_queue_set_status(struct iwl_trans *trans, | |||
430 | 430 | ||
431 | txq->sched_retry = scd_retry; | 431 | txq->sched_retry = scd_retry; |
432 | 432 | ||
433 | IWL_DEBUG_INFO(trans, "%s %s Queue %d on FIFO %d\n", | 433 | IWL_DEBUG_TX_QUEUES(trans, "%s %s Queue %d on FIFO %d\n", |
434 | active ? "Activate" : "Deactivate", | 434 | active ? "Activate" : "Deactivate", |
435 | scd_retry ? "BA" : "AC/CMD", txq_id, tx_fifo_id); | 435 | scd_retry ? "BA" : "AC/CMD", txq_id, tx_fifo_id); |
436 | } | 436 | } |
@@ -561,12 +561,13 @@ int iwl_trans_pcie_tx_agg_alloc(struct iwl_trans *trans, | |||
561 | 561 | ||
562 | tid_data = &trans->shrd->tid_data[sta_id][tid]; | 562 | tid_data = &trans->shrd->tid_data[sta_id][tid]; |
563 | if (tid_data->tfds_in_queue == 0) { | 563 | if (tid_data->tfds_in_queue == 0) { |
564 | IWL_DEBUG_HT(trans, "HW queue is empty\n"); | 564 | IWL_DEBUG_TX_QUEUES(trans, "HW queue is empty\n"); |
565 | tid_data->agg.state = IWL_AGG_ON; | 565 | tid_data->agg.state = IWL_AGG_ON; |
566 | iwl_start_tx_ba_trans_ready(priv(trans), ctx, sta_id, tid); | 566 | iwl_start_tx_ba_trans_ready(priv(trans), ctx, sta_id, tid); |
567 | } else { | 567 | } else { |
568 | IWL_DEBUG_HT(trans, "HW queue is NOT empty: %d packets in HW" | 568 | IWL_DEBUG_TX_QUEUES(trans, |
569 | "queue\n", tid_data->tfds_in_queue); | 569 | "HW queue is NOT empty: %d packets in HW" |
570 | " queue\n", tid_data->tfds_in_queue); | ||
570 | tid_data->agg.state = IWL_EMPTYING_HW_QUEUE_ADDBA; | 571 | tid_data->agg.state = IWL_EMPTYING_HW_QUEUE_ADDBA; |
571 | } | 572 | } |
572 | spin_unlock_irqrestore(&trans->shrd->sta_lock, flags); | 573 | spin_unlock_irqrestore(&trans->shrd->sta_lock, flags); |
@@ -643,14 +644,15 @@ int iwl_trans_pcie_tx_agg_disable(struct iwl_trans *trans, | |||
643 | 644 | ||
644 | /* The queue is not empty */ | 645 | /* The queue is not empty */ |
645 | if (write_ptr != read_ptr) { | 646 | if (write_ptr != read_ptr) { |
646 | IWL_DEBUG_HT(trans, "Stopping a non empty AGG HW QUEUE\n"); | 647 | IWL_DEBUG_TX_QUEUES(trans, |
648 | "Stopping a non empty AGG HW QUEUE\n"); | ||
647 | trans->shrd->tid_data[sta_id][tid].agg.state = | 649 | trans->shrd->tid_data[sta_id][tid].agg.state = |
648 | IWL_EMPTYING_HW_QUEUE_DELBA; | 650 | IWL_EMPTYING_HW_QUEUE_DELBA; |
649 | spin_unlock_irqrestore(&trans->shrd->sta_lock, flags); | 651 | spin_unlock_irqrestore(&trans->shrd->sta_lock, flags); |
650 | return 0; | 652 | return 0; |
651 | } | 653 | } |
652 | 654 | ||
653 | IWL_DEBUG_HT(trans, "HW queue is empty\n"); | 655 | IWL_DEBUG_TX_QUEUES(trans, "HW queue is empty\n"); |
654 | turn_off: | 656 | turn_off: |
655 | trans->shrd->tid_data[sta_id][tid].agg.state = IWL_AGG_OFF; | 657 | trans->shrd->tid_data[sta_id][tid].agg.state = IWL_AGG_OFF; |
656 | 658 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c b/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c index da3411057afc..a1a58330273f 100644 --- a/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c +++ b/drivers/net/wireless/iwlwifi/iwl-trans-pcie.c | |||
@@ -1231,7 +1231,7 @@ static int iwl_trans_pcie_tx(struct iwl_trans *trans, struct sk_buff *skb, | |||
1231 | txq->need_update = 1; | 1231 | txq->need_update = 1; |
1232 | iwl_txq_update_write_ptr(trans, txq); | 1232 | iwl_txq_update_write_ptr(trans, txq); |
1233 | } else { | 1233 | } else { |
1234 | iwl_stop_queue(trans, txq); | 1234 | iwl_stop_queue(trans, txq, "Queue is full"); |
1235 | } | 1235 | } |
1236 | } | 1236 | } |
1237 | return 0; | 1237 | return 0; |
@@ -1283,20 +1283,21 @@ static int iwlagn_txq_check_empty(struct iwl_trans *trans, | |||
1283 | /* aggregated HW queue */ | 1283 | /* aggregated HW queue */ |
1284 | if ((txq_id == tid_data->agg.txq_id) && | 1284 | if ((txq_id == tid_data->agg.txq_id) && |
1285 | (q->read_ptr == q->write_ptr)) { | 1285 | (q->read_ptr == q->write_ptr)) { |
1286 | IWL_DEBUG_HT(trans, | 1286 | IWL_DEBUG_TX_QUEUES(trans, |
1287 | "HW queue empty: continue DELBA flow\n"); | 1287 | "HW queue empty: continue DELBA flow\n"); |
1288 | iwl_trans_pcie_txq_agg_disable(trans, txq_id); | 1288 | iwl_trans_pcie_txq_agg_disable(trans, txq_id); |
1289 | tid_data->agg.state = IWL_AGG_OFF; | 1289 | tid_data->agg.state = IWL_AGG_OFF; |
1290 | iwl_stop_tx_ba_trans_ready(priv(trans), | 1290 | iwl_stop_tx_ba_trans_ready(priv(trans), |
1291 | NUM_IWL_RXON_CTX, | 1291 | NUM_IWL_RXON_CTX, |
1292 | sta_id, tid); | 1292 | sta_id, tid); |
1293 | iwl_wake_queue(trans, &trans_pcie->txq[txq_id]); | 1293 | iwl_wake_queue(trans, &trans_pcie->txq[txq_id], |
1294 | "DELBA flow complete"); | ||
1294 | } | 1295 | } |
1295 | break; | 1296 | break; |
1296 | case IWL_EMPTYING_HW_QUEUE_ADDBA: | 1297 | case IWL_EMPTYING_HW_QUEUE_ADDBA: |
1297 | /* We are reclaiming the last packet of the queue */ | 1298 | /* We are reclaiming the last packet of the queue */ |
1298 | if (tid_data->tfds_in_queue == 0) { | 1299 | if (tid_data->tfds_in_queue == 0) { |
1299 | IWL_DEBUG_HT(trans, | 1300 | IWL_DEBUG_TX_QUEUES(trans, |
1300 | "HW queue empty: continue ADDBA flow\n"); | 1301 | "HW queue empty: continue ADDBA flow\n"); |
1301 | tid_data->agg.state = IWL_AGG_ON; | 1302 | tid_data->agg.state = IWL_AGG_ON; |
1302 | iwl_start_tx_ba_trans_ready(priv(trans), | 1303 | iwl_start_tx_ba_trans_ready(priv(trans), |
@@ -1354,7 +1355,7 @@ static void iwl_trans_pcie_reclaim(struct iwl_trans *trans, int sta_id, int tid, | |||
1354 | ssn , tfd_num, txq_id, txq->swq_id); | 1355 | ssn , tfd_num, txq_id, txq->swq_id); |
1355 | freed = iwl_tx_queue_reclaim(trans, txq_id, tfd_num, skbs); | 1356 | freed = iwl_tx_queue_reclaim(trans, txq_id, tfd_num, skbs); |
1356 | if (iwl_queue_space(&txq->q) > txq->q.low_mark && cond) | 1357 | if (iwl_queue_space(&txq->q) > txq->q.low_mark && cond) |
1357 | iwl_wake_queue(trans, txq); | 1358 | iwl_wake_queue(trans, txq, "Packets reclaimed"); |
1358 | } | 1359 | } |
1359 | 1360 | ||
1360 | iwl_free_tfds_in_queue(trans, sta_id, tid, freed); | 1361 | iwl_free_tfds_in_queue(trans, sta_id, tid, freed); |
@@ -1418,7 +1419,8 @@ static int iwl_trans_pcie_resume(struct iwl_trans *trans) | |||
1418 | #endif /* CONFIG_PM_SLEEP */ | 1419 | #endif /* CONFIG_PM_SLEEP */ |
1419 | 1420 | ||
1420 | static void iwl_trans_pcie_wake_any_queue(struct iwl_trans *trans, | 1421 | static void iwl_trans_pcie_wake_any_queue(struct iwl_trans *trans, |
1421 | enum iwl_rxon_context_id ctx) | 1422 | enum iwl_rxon_context_id ctx, |
1423 | const char *msg) | ||
1422 | { | 1424 | { |
1423 | u8 ac, txq_id; | 1425 | u8 ac, txq_id; |
1424 | struct iwl_trans_pcie *trans_pcie = | 1426 | struct iwl_trans_pcie *trans_pcie = |
@@ -1426,11 +1428,11 @@ static void iwl_trans_pcie_wake_any_queue(struct iwl_trans *trans, | |||
1426 | 1428 | ||
1427 | for (ac = 0; ac < AC_NUM; ac++) { | 1429 | for (ac = 0; ac < AC_NUM; ac++) { |
1428 | txq_id = trans_pcie->ac_to_queue[ctx][ac]; | 1430 | txq_id = trans_pcie->ac_to_queue[ctx][ac]; |
1429 | IWL_DEBUG_INFO(trans, "Queue Status: Q[%d] %s\n", | 1431 | IWL_DEBUG_TX_QUEUES(trans, "Queue Status: Q[%d] %s\n", |
1430 | ac, | 1432 | ac, |
1431 | (atomic_read(&trans_pcie->queue_stop_count[ac]) > 0) | 1433 | (atomic_read(&trans_pcie->queue_stop_count[ac]) > 0) |
1432 | ? "stopped" : "awake"); | 1434 | ? "stopped" : "awake"); |
1433 | iwl_wake_queue(trans, &trans_pcie->txq[txq_id]); | 1435 | iwl_wake_queue(trans, &trans_pcie->txq[txq_id], msg); |
1434 | } | 1436 | } |
1435 | } | 1437 | } |
1436 | 1438 | ||
@@ -1453,11 +1455,12 @@ static struct iwl_trans *iwl_trans_pcie_alloc(struct iwl_shared *shrd) | |||
1453 | return iwl_trans; | 1455 | return iwl_trans; |
1454 | } | 1456 | } |
1455 | 1457 | ||
1456 | static void iwl_trans_pcie_stop_queue(struct iwl_trans *trans, int txq_id) | 1458 | static void iwl_trans_pcie_stop_queue(struct iwl_trans *trans, int txq_id, |
1459 | const char *msg) | ||
1457 | { | 1460 | { |
1458 | struct iwl_trans_pcie *trans_pcie = IWL_TRANS_GET_PCIE_TRANS(trans); | 1461 | struct iwl_trans_pcie *trans_pcie = IWL_TRANS_GET_PCIE_TRANS(trans); |
1459 | 1462 | ||
1460 | iwl_stop_queue(trans, &trans_pcie->txq[txq_id]); | 1463 | iwl_stop_queue(trans, &trans_pcie->txq[txq_id], msg); |
1461 | } | 1464 | } |
1462 | 1465 | ||
1463 | #define IWL_FLUSH_WAIT_MS 2000 | 1466 | #define IWL_FLUSH_WAIT_MS 2000 |
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans.h b/drivers/net/wireless/iwlwifi/iwl-trans.h index 1ecdd1c2943d..7839362b9c0b 100644 --- a/drivers/net/wireless/iwlwifi/iwl-trans.h +++ b/drivers/net/wireless/iwlwifi/iwl-trans.h | |||
@@ -171,7 +171,8 @@ struct iwl_trans_ops { | |||
171 | void (*tx_start)(struct iwl_trans *trans); | 171 | void (*tx_start)(struct iwl_trans *trans); |
172 | 172 | ||
173 | void (*wake_any_queue)(struct iwl_trans *trans, | 173 | void (*wake_any_queue)(struct iwl_trans *trans, |
174 | enum iwl_rxon_context_id ctx); | 174 | enum iwl_rxon_context_id ctx, |
175 | const char *msg); | ||
175 | 176 | ||
176 | int (*send_cmd)(struct iwl_trans *trans, struct iwl_host_cmd *cmd); | 177 | int (*send_cmd)(struct iwl_trans *trans, struct iwl_host_cmd *cmd); |
177 | 178 | ||
@@ -196,7 +197,7 @@ struct iwl_trans_ops { | |||
196 | 197 | ||
197 | void (*free)(struct iwl_trans *trans); | 198 | void (*free)(struct iwl_trans *trans); |
198 | 199 | ||
199 | void (*stop_queue)(struct iwl_trans *trans, int q); | 200 | void (*stop_queue)(struct iwl_trans *trans, int q, const char *msg); |
200 | 201 | ||
201 | int (*dbgfs_register)(struct iwl_trans *trans, struct dentry* dir); | 202 | int (*dbgfs_register)(struct iwl_trans *trans, struct dentry* dir); |
202 | int (*check_stuck_queue)(struct iwl_trans *trans, int q); | 203 | int (*check_stuck_queue)(struct iwl_trans *trans, int q); |
@@ -277,9 +278,10 @@ static inline void iwl_trans_tx_start(struct iwl_trans *trans) | |||
277 | } | 278 | } |
278 | 279 | ||
279 | static inline void iwl_trans_wake_any_queue(struct iwl_trans *trans, | 280 | static inline void iwl_trans_wake_any_queue(struct iwl_trans *trans, |
280 | enum iwl_rxon_context_id ctx) | 281 | enum iwl_rxon_context_id ctx, |
282 | const char *msg) | ||
281 | { | 283 | { |
282 | trans->ops->wake_any_queue(trans, ctx); | 284 | trans->ops->wake_any_queue(trans, ctx, msg); |
283 | } | 285 | } |
284 | 286 | ||
285 | 287 | ||
@@ -339,9 +341,10 @@ static inline void iwl_trans_free(struct iwl_trans *trans) | |||
339 | trans->ops->free(trans); | 341 | trans->ops->free(trans); |
340 | } | 342 | } |
341 | 343 | ||
342 | static inline void iwl_trans_stop_queue(struct iwl_trans *trans, int q) | 344 | static inline void iwl_trans_stop_queue(struct iwl_trans *trans, int q, |
345 | const char *msg) | ||
343 | { | 346 | { |
344 | trans->ops->stop_queue(trans, q); | 347 | trans->ops->stop_queue(trans, q, msg); |
345 | } | 348 | } |
346 | 349 | ||
347 | static inline int iwl_trans_wait_tx_queue_empty(struct iwl_trans *trans) | 350 | static inline int iwl_trans_wait_tx_queue_empty(struct iwl_trans *trans) |